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

How to I get info from a detail line into a group header?

Status
Not open for further replies.

melburstein

Technical User
Aug 29, 2000
246
US
I am a new user of Microsoft SQL Server 2000 Reporting Services and I need your help.

Let us say that my report has only one group and that group is "Client Name" (it is actually grouped by "Branch" and then "Client Name"). Here is a similified illustration of the detail lines within a group. Again, these are detail lines.

Client Product
Name Lines

ABC Mfg Inc. AF
ABC Mfg Inc. BAL
ABC Mfg Inc. AF
ABC Mfg Inc. TAP

Each detail line has other info as well, but that is not important to this illustration.

Detail lines are hidden in my report. All I am interested in is the group header lines. one for each "Client Name". This is the information that I want to see in the group header line:

ABC Mfg Inc. AF, BAL, TAP

Can someone suggest a way to accomplish this. There are fewer than 10 different Product Lines. A group of detail lines for a Client Name could be in the hundreds.

Thank you for your help.

Mel
 
Does the data come from a stored procedure? Perhaps you can calculate the distinct product lines on the database side?
 
Take a look at this thread from the SQL Server Programming forum: thread183-906921
 
All you should have to do is bind your table (I used a table, not a matrix) to your dataset. Create a group and bind it to the dataset. Add a textbox to the group Header field and drag over the ClientName from the Fields toolbox. You should see Fields!ClientName.Value in your textbox. Now, you can create an expression (which is what I did) that has "ClientName " & Fields!ClientName.Value for more user friendly readability, but that's your choice.

Then stick the other details on the details line and you should be fine.

One thing you might want to look into is Nesting a couple of groups. Especially if you have groups of ProductLines. So your 1st Group is based on ClientName and your Second Group is based on ProductLine and then all the details fall under the detail line and you can have RS suppress the details unless the end user toggles the little + sign to the side.

Hope that helps!



Catadmin - MCDBA, MCSA
"The only stupid question is the one that *wasn't* asked.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top