How does Master-Detail work against the database?

Stimulsoft Reports.NET discussion
Post Reply
fuhrj
Posts: 120
Joined: Wed Jun 11, 2008 12:51 pm
Location: Lancaster, Ohio

How does Master-Detail work against the database?

Post by fuhrj »

I wrote a simple Master-Detail report which works correctly. However, my concern is how the child datasource retrieves its data. Here is my setup:

Code: Select all

Master Datasource:

SELECT * FROM tblCustomer WHERE customerID=5

Code: Select all

Child Datasource:

SELECT * FROM tblEmployees
I set up a Relation for "customerID".

When this report is executed does it pull all of the records from tblEmployees and then filter based on Relation? Or will it connect to the database and only pull records from tblEmployee that match the master data's customerID?

From a performance standpoint, I don't want it pulling all of the records from tblEmployees. I can add the WHERE condition to the child datasource, but I wanted to see if that was necessary.
Jan
Posts: 1265
Joined: Thu Feb 19, 2009 8:19 am

How does Master-Detail work against the database?

Post by Jan »

Hello,

Please check sample application Demo from standard delivery. Report name - SQL.Master-Detail with Parameters.

Thank you.
Post Reply