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

Supressing More than one Occurrence

Status
Not open for further replies.

shelby55

Technical User
Jun 27, 2003
1,229
CA
Hello

I am using Crystal 9 with an Access 2000 database on a Windows XP/SP2 computer.

I have a database of diagnoses. The fields include diagnosis, diagnosis prefix, occurrence and total occurrence. The diagnosis table links to the visit table as a many to one relationship.

Each visit should only have one diagnosis with a prefix of "R" but some have many due to an error made by data entry staff. I can't get the data corrected from the source but need to have a field for each one which will be used in other formulae. How will I do this? Note that I want the first occurrence of the prefix R.

All help is greatly appreciated.
 
'Note that I want the first occurrence of the prefix R.'

Does 'first' have any meaning here? is it literally the first one you find, whichever that might be, or is there more significance to the word 'first'.

 
Group by visit. Suppress the detail lines and show just one set of details, in the group header or footer.

Note that this will put the report into visit sequence. You could get round this by having 'diagnoses' as a higher group.

If you also want a report showing how many multiple entries have been made, use Save As to make a copy, restore display of details, add a count and use Report > Selection Formulas > Group to suppress all groups where there is just one. Something you could show to whoever is in change to data input.

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
[yinyang] Windows XP & Crystal 10 [yinyang]
 
I overlooked the mention of 'R'. If what you want is just to suppress those and to show other details, then use section suppression. Right-click on the detail section and choose Section Expert. Then choose the formula icon (x+2 and a pencil) for suppression. Enter a formula; e.g.
Code:
left({diagnosis}, 1) = "R"
and {diagnosis} = Previous({diagnosis})

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
[yinyang] Windows XP & Crystal 10 [yinyang]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top