Solved

Reporting Services Passing Sum from subreport to Main report

Posted on 2009-07-14
4
902 Views
Last Modified: 2012-05-07
Hello experts,

I have a report that I created with a few subreports.  I would like to pass the sum from various columns in the subreport to the main report to do some calculations.  Is there anyway I can accomplish this?  Either via passing it as a parameter or set a string somewhere and pass that?
0
Comment
Question by:holemania
  • 2
  • 2
4 Comments
 
LVL 14

Expert Comment

by:Emes
ID: 24852038
You can do this by selecting the expression component.

Then select the data source you want the sum  from.

Then select the data field.

Please note you can only take sums and first field from another Data source.

 


DATAS.bmp
0
 

Author Comment

by:holemania
ID: 24853196
That would've work if I created multiple datasets within the same report.  However, the way how I create my report, I setup the main report and then from that main report, I created several sub reports.  Each sub report has its own dataset.  Now I can pass the ID from the main report to the other subreports as parameter.  However, I need to pass the sum of these subreports back to the main report for calculations and that's where my problem is.  

I can take each dataset from each of the subreport and put it in the main, but that would mean I have to recreate all the calculated fields and there's a lot of those.  Any thought?  What about property code section?  Can that be done to pass a shared variable?
0
 
LVL 14

Accepted Solution

by:
Emes earned 500 total points
ID: 24853476
If you cut and paste the tables into one report why do you have to recreate the fields?

even if you do I would take the xml code and the do a search and replace on it if you have the same dataset names.

either way I would put everything into one report so you have easy access to all the needed data.
0
 

Author Comment

by:holemania
ID: 24870726
I think it could work if I create everything on the main page.  I'm just used to doing this in crystal report via creating subreport and passing data back and forth.
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Written by Valentino Vranken. Introduction: In a previous article (http://www.experts-exchange.com/articles/Microsoft/Development/MS-SQL-Server/MS-SQL_Reporting/Reporting-On-Data-From-Stored-Procedures-part-1.html) I announced that I would writ…
Time Corrections for Reports Working with a report, we made some interesting discoveries about the time corrections/updates We are using the following Parameters: Starting Entered Date (Date) formatted as Data type: "Date/Time" Ending Entered …
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now