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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiple subreports to run off the same selected data

Status
Not open for further replies.

pvirsf

Technical User
Aug 30, 2004
35
US
Is it true that subreports run independently and independently retrieve data from the data source per the tables, links, and selection defined in the subreport?

I am running CR 9 on a MS SQL Server db.
I want to have 4 subreports with different grouping and totaling schemes, run from a primary report and they would ordinarily run on identical sets of data.

I am wondering if performance would be improved if a single common selection of data could be done in the primary report for subsequent individual grouping, totaling, etc by each of the 4 subreports? Any thoughts out there?
 
Your question seems more appropriate for the Crystal Reports forum. Reports and subreports are not part of SQL or SQL Server.

As to the SQL Server performance, it is so fast that it really doesnt matter whether you SELECT and GROUP BY four times or prepare a temporary table with one SELECT then do the four GROUP BY queries on the smaller dataset. The SELECT would have to be extraordinarily complex and involve an enourmous number of rows from an incredibly poorly designed database before the latter approach would offer any advantage.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top