Skip to Content

Group Selection Filter after comparison of data

I have a Crystal Report where I need to include all patients with an office visit with the diagnosis code of 362.52.

However, that patient must also have at least one other visit where they had a procedure code of 67036.

The issue is that the diagnosis code of 362.52 and procedure code of 67036 would almost never occur at the same visit, so I would have to do some soft of group filtering.

Any help creating the correct formula field(s) and group selection formula would be appreciated!

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Nov 11, 2016 at 08:17 AM

    Hi Cheryl,

    1. Create a formula (@Code1) with this code:

    If {diag_code} = 362.52 then 1

    2. Create a formula (@Code2) with this code:

    If {procedure_code} = 67036 then 1

    3. Add a group selection formula with this code:

    Maximum({@Code1}, {PatientID}) = 1 AND

    Maximum({@Code2}, {PatientID}) = 1

    -Abhilash

    Add comment
    10|10000 characters needed characters exceeded

  • Dec 27, 2016 at 10:31 PM

    Thank you!

    Add comment
    10|10000 characters needed characters exceeded