Page 1 of 1

Filter by multiple refering physicians

Posted: Tue Jun 21, 2011 12:50 pm
by slateszj
I've been trying to get the system to filter a user's study list for multiple referring dr's. I can get one to work... but not two or more.

In ADvanced Expression: I entered:

(referringPhysicianName like '%A%' ) OR (referringPhysicianName like '%B%' )
- this will result in dr A's studies coming up...but not b (visa versa if i switch them)

Why doesn't it work?

Re: Filter by multiple refering physicians

Posted: Tue Jun 21, 2011 1:11 pm
by jeremy
Hello -

Please use a lower case "or" statement

((referringPhysicianName like '%A%' ) or (referringPhysicianName like '%B%' ))

Regards,
Jeremy

Re: Filter by multiple refering physicians

Posted: Tue Jun 21, 2011 1:32 pm
by slateszj
Great! thanks so much!

Re: Filter by multiple refering physicians

Posted: Wed Jun 22, 2011 11:06 pm
by tom
A more general formula you could use would be this:

upper(referringPhysicianName) in ( 'NAME' , 'ANOTHERNAME' , 'THIRDNAME' )

This way, you can add more names just by typing a comma at the end of the list and adding a new name in single quotes

also by using the term "upper" to modify "referringPhysicianName", and putting all the names in all-caps, you avoid mismatches due to capitalization

i.e., if the tech enters BROWN and your rule is matching Brown, you wouldn't want this to be missed because of case-sensitivity

Re: Filter by multiple refering physicians

Posted: Thu Jun 23, 2011 8:46 am
by justin
Also, using the "contains" keyword may be a simpler way of doing this. It is case insensitive and will locate the keyword anywhere in the string.

(referringPhysicianName contains 'a' or referringPhysicianName contains 'b')

Justin