This is a migrated thread and some comments may be shown as answers.

SubReport question

3 Answers 125 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Will
Top achievements
Rank 1
Will asked on 22 Nov 2007, 09:21 PM
Hello -

In the examples in the Help documentation on how to create a subreport (for the Creating Master-Detail Reports using SubReports heading), the query that is used for the Detail (SubReport) joins a few tables and then uses (I assume) the Report Parameter and Filter properties to "filter" the data to be for a specifc product category id. 

My question is this:  Does this subreport bring down all of the data that matches the sql query to the client and THEN applies the filter condition?  Since the query's WHERE clause does not include a statement like "WHERE ProductCategoryID = 12" or whatever the incoming parameter value is, which would filter the data at the database query level, I am assuming that the report engine gathers ALL of the query results and then applies a filter at the local or client level.  Is that correct?

Thanks
 - will

3 Answers, 1 is accepted

Sort by
0
Svetoslav
Telerik team
answered on 23 Nov 2007, 08:37 AM
Hello Will,

This is exactly what this example illustrates - you acquire all the data for the subreport at once and then filter it on the report level. To do this you need to define report filters and if needed report parameters.

As far as the data filtering is concerned there are two possible ways - filter the data before passing it to the report or leave the report to filter it - for more information please refer to this help topic.

I hope this information helps.

Sincerely yours,
Svetoslav
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Will
Top achievements
Rank 1
answered on 23 Nov 2007, 06:38 PM
Thanks.
If I wanted to filter the data at the database server (before bringing it to the report) and using your example from the Help documentation, would I just be able to add an additional statement to the WHERE clause (WHERE ProductCategoryID = @ID) and then create a new parameter at the report level (@ID)?
0
Svetoslav
Telerik team
answered on 26 Nov 2007, 10:13 AM
Hello Will,

The only parameters supported at the moment are the report parameters. We do noth support data source parameters yet. For this reason there is no way to link both - at least at the moment. This movie illustrates how to use a data source with parameters and pass values from outside to the data source parameters.
 

Sincerely yours,
Svetoslav
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
General Discussions
Asked by
Will
Top achievements
Rank 1
Answers by
Svetoslav
Telerik team
Will
Top achievements
Rank 1
Share this question
or