2012年2月16日星期四
BC30451 Name 'whatever' is not declared
group header, have a formula that shows that group's total as a % of
the grand total. Example:
Name Sales % of total
Tom 5 25%
Joe 15 75%
so, in my table, I have a table footer with a textbox "textbox1" with
the formula
=SUM(Fields!SALES.Value )
and in the group1 header, i have a textbox "textbox2". For the formula,
i put:
=Fields!SALES.Value / textbox1.value
This works in access, but apparently not in RS (?). I get an error
message that textbox1 is not declared. It seems like I must be missing
something simple here. Any Ideas? I could put subqueries in my dataset
I suppose, but that seems like an awfully long way around to do what I
need. Thanks in advance...
EricWill ReportItems!Textbox1.Value work?
Steve MunLeeuw
<c-eric.geil@.mci.com> wrote in message
news:1161292630.251749.186250@.k70g2000cwa.googlegroups.com...
> I'm migrating a report from access to RS. What I want to do is for each
> group header, have a formula that shows that group's total as a % of
> the grand total. Example:
> Name Sales % of total
> Tom 5 25%
> Joe 15 75%
> so, in my table, I have a table footer with a textbox "textbox1" with
> the formula
> =SUM(Fields!SALES.Value )
> and in the group1 header, i have a textbox "textbox2". For the formula,
> i put:
> =Fields!SALES.Value / textbox1.value
> This works in access, but apparently not in RS (?). I get an error
> message that textbox1 is not declared. It seems like I must be missing
> something simple here. Any Ideas? I could put subqueries in my dataset
> I suppose, but that seems like an awfully long way around to do what I
> need. Thanks in advance...
>
> Eric
>|||that worked...thanks!
What's the deal with the expression builder? It seems like it would
have some functions and/or controls listed in there to give the user
some clue as to their verbiage...
thanks again..
eric
2012年2月9日星期四
basic sql question
I need to add all the records being counted for all groups.
I would like to add this count for each group into a total for all
groups( the 8 rows). Is this possible?
MSG_CD MSG_TEXT
COUNT(CCHDBA.III_SYNC_RESULT.I
-- ----------------
----------
E1349 SID NOT FOUND IN CCH DATA
254
E1350 STATUS FLAG DOES NOT MATCH
19
E1351 FBI NUMBER IN CCH DOESNT EXIST IN FBI SYNC TAPE
47
E1352 FBI NAME NOT FOUND IN CCH
227
E1353 FBI DOB DOESNT MATCH DOB IN CCH
2
E1354 FBI SEX CODE DOESNT MATCH IN CCH
46
E1355 FBI RACE CODE DOESNT MATCH IN CCH
2998
E1379 SID IN CCH NOT IN FBI SYNC - FBI NUMBER DOES EXIST
25
8 rows selected
SQL
SELECT
CCHDBA.III_RESULT_MESSAGE_XREF.MSG_CD,
CCH_MESSAGE.MSG_TEXT,
count(CCHDBA.III_SYNC_RESULT.III_RESULT_ID)
FROM CCHDBA.III_SYNC_RESULT,
CCHDBA.III_RESULT_MESSAGE_XREF,
CCH_MESSAGE
WHERE ( III_SYNC_RESULT.III_RESULT_ID =
CCHDBA.III_RESULT_MESSAGE_XREF.III_RESULT_ID )
AND ( III_RESULT_MESSAGE_XREF.MSG_CD = CCH_MESSAGE.MSG_CD )
GROUP BY CCHDBA.III_RESULT_MESSAGE_XREF.MSG_CD,
CCH_MESSAGE.MSG_TEXT;
Inappropriate post?
If so, Red Flag it!jwa6 (jwagans@.yahoo.com) writes:
> I need to add all the records being counted for all groups.
> I would like to add this count for each group into a total for all
> groups( the 8 rows). Is this possible?
I will have to admit that I don't understand what you are looking
for.
The standard recommendation for this type of question is to include:
o CREATE TABLE statements for your table.
o INSERT statements with sample data (just enough rows to demonstrate
the problem.)
o The desired result given the sample.
o A short narrative of what you are trying to achieve.
This permits people to post a tested solution to your problem.
--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp|||"jwa6" <jwagans@.yahoo.com> wrote in message
news:1111693328.831625.88890@.f14g2000cwb.googlegro ups.com...
> hi
> I need to add all the records being counted for all groups.
> I would like to add this count for each group into a total for all
> groups( the 8 rows). Is this possible?
If I understand you correctly, you could add WITH ROLLUP to the GROUP BY
clause. Having said that, your post looks rather like Oracle, not MSSQL - if
so, you should probably post in an Oracle group to get a better answer. If
you are using MSSQL, then as Erland said, please post some code to show
exactly what you want.
Simon