Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026 Agenda Now Available: Explore Sessions
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

If statement. Need help

I work for a health system. We are trying to calculate new patient visits vs follow up visits.

The only variable we have to measure difference are CPT codes that are created each time a person comes in whether for a new visit or follow up. Unfortunately CPT codes for new patient visits are exclusive for new patients but follow up CPT codes could also go into new visits.

We tried this function.

If (match (CPT code '1111','2222' etc), 'new')

if not( match (CPT code '1111','2222' etc), 'follow up')

I am not big on coding so please excuse if this looks remedial.

The main goal is to find a statement that will

1. mark a patient visit NEW if the visit contains even 1 CPT code that is in the new list.

2. Will only mark it as a follow up visit if there are no new CPT codes within the visit.

Please let me know if you need more clarification. Any help would be very much appreciated.

Thanks

20 Replies
Anonymous
Not applicable
Author

Sorry, did not work. We are giving it to the BI team. Hopefully they can make it work.