Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Visual Studio Report Designer - Grand Total Sums Wrong?

Status
Not open for further replies.

misscrf

Technical User
Jun 7, 2004
1,344
US
I have a report that I am creating in Visual Studio 2005. This is what the data looks like:

Code:
SELECT     tbl1.Created, tbl2.Name AS Type, tbl3.DocExt, MAX(tbl1.ItemCount) AS ItemCount, 
                      MAX(tbl1.ItemTotal) AS ItemTotal, MAX(tbl1.RecordsWritten) AS RecordsWritten, MAX(tbl1.Size) AS Size, 
                      COUNT(tbl3.DocID) AS CountOfDocID
FROM         tbl3 WITH (nolock) LEFT OUTER JOIN
                      tbl2 WITH (nolock) ON tbl2.ID = tbl3.TypeID LEFT OUTER JOIN
                      tbl1 WITH (NOLOCK) ON tbl3.EDSessionID = tbl1.ID
GROUP BY tbl1.Created, tbl2.Name, tbl3.DocExt

This is what the layout looks like:


This is what the preview looks like, which is summing the group 1 stuff, but gives me wrong totals.


I have looked all over for how to correct this, but you will see that the sum of the item totals is all wrong. How do I fix this please?


misscrf

It is never too late to become what you could have been ~ George Eliot
 
can no one help me?

misscrf

It is never too late to become what you could have been ~ George Eliot
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top