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

Grouping, Selecting Records

Status
Not open for further replies.

thawkins99

Programmer
Sep 20, 2005
2
0
0
US
Hi thanks in advance. I need help selecting records. I'm using the following data

Name,department,codes
SusanR,Receiving, 1111
JaneS, AP, 2341
SusanR,H/R, 3378

I need to group by name, by department,this is where I need help. I also need to include any record that SusanR appears in even if she is in a different department. Using the above scenario I would get the following results:

SusanR,Receiving, 1111
SusanR,H/R, 3378
 
What's the problem? You haven't said what you'd like the result to be.

If you want to group by department within name and also name within department, this can be done using a Crosstab or a Subreport.

Running totals can accumulate using some formula, e.g. for a particular name. If you're not already familiar with Crystal's automated totals, see FAQ767-6524.

[yinyang] Madawc Williams (East Anglia, UK). Using Crystal 11.5 with SQL and Windows XP [yinyang]
 
If you group by Name and then by Dept, you would get all of SusanR's records together. Then just place each field in the detail section and suppress the group headers and group footers.

-LB
 
You could also create a formula that is a combination of the name and department and then group by that formula.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top