reportdr
Technical User
- Apr 11, 2006
- 10
Hello
I am working with Crystal 8.5 accessing data from an SQL database.
I am working with a patient data database. I require data from the diagnoses table as well as the procedures table so I am using subreports.
The main reports is the demographic data and then a subreport each for procedures and diagnoses. There can be up to 25 diagnoses per abstract and 20 procedures.
Currently the data is in table format such as:
Occur Code Type Chart No
1 J45. M 1234
2 C64.0 1 1234
3 P48.9 1 1234
1 J66.4 M 5555
1 K59.5 M 6666
However I need the data to show as
Chart No Dx 1 Dx 2 Dx 3
1234 J45. C64.0 P48.9
I thought I could just create formulae indicating "if occur = 1 then DxCode" for Dx 1, "if occur = 2 then DxCode else "" " for dx2 etc. and place these formulae in the group header which is the unique identifier (different than chart number). But that didn't work - only Dx 1 showed anything even though the data I was tasting had more than 1 diagnosis per chart.
What am I missing? Thanks.
I am working with Crystal 8.5 accessing data from an SQL database.
I am working with a patient data database. I require data from the diagnoses table as well as the procedures table so I am using subreports.
The main reports is the demographic data and then a subreport each for procedures and diagnoses. There can be up to 25 diagnoses per abstract and 20 procedures.
Currently the data is in table format such as:
Occur Code Type Chart No
1 J45. M 1234
2 C64.0 1 1234
3 P48.9 1 1234
1 J66.4 M 5555
1 K59.5 M 6666
However I need the data to show as
Chart No Dx 1 Dx 2 Dx 3
1234 J45. C64.0 P48.9
I thought I could just create formulae indicating "if occur = 1 then DxCode" for Dx 1, "if occur = 2 then DxCode else "" " for dx2 etc. and place these formulae in the group header which is the unique identifier (different than chart number). But that didn't work - only Dx 1 showed anything even though the data I was tasting had more than 1 diagnosis per chart.
What am I missing? Thanks.