Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Creating aggregates on SSRS


Creating aggregates on SSRS

Author
Message
sneupan1
sneupan1
Forum Newbie
Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)

Group: General Forum Members
Points: 1 Visits: 9
Hi Everyone,

I have been working on a SSRS report and could not make it work.

I have a data set like shown below:

Data Set
Item Order OrdQty Comp Qty Cost
X Z 10 A 4 41
X Z 10 B 5 45
X Y 5 C 6 24
X Y 5 D 4 21
X W 20 E 2 40

I would like to have a result like shown below:

Result
Item Order OrdQty Comp Qty Cost
X Z 10 A 4 41
B 5 45
OrdTotal 10 9 86
Y 5 C 6 24
D 4 21
OrdTotal 5 10 45
W 20 E 2 40
OrdTotal 20 2 40

ItemTotal 35 9 171

9 I was wable to get right ItemTotal for Qty
171 I was able to get right ItemTotal for Cost
35 I could not get this working. I tried expression sum(avg(OrdQty))

I was able to get right value for Qty and cost but I could not get a right value for ItemTotal by trying few things. One of the expressions I tried is shown above. Any help will be highly appreciated.

Thanks

Sar
geoff5
geoff5
SSC-Enthusiastic
SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)SSC-Enthusiastic (180 reputation)

Group: General Forum Members
Points: 180 Visits: 543
I suspect the problem can be resolved by applying a "scope" to one or both of your aggregate functions. It is difficult to tell for sure because of the lack of formatting in your post. Perhaps a screenshot showing the tablix and highlighting the value that you are having trouble with would help clarify the solution.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search