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

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Expression consolidation

Can the following two expressions be combined into one expression:

Screen Shot 2016-02-04 at 07.40.20.png

Thanking you in advance

Regards.

Labels (1)
11 Replies
Anonymous
Not applicable
Author

Try this?

if(len(trim([Doctor Number])) = 0 or IsNull([Doctor Number]), '00000',

if(len(trim([Doctor Number])) >= 7 and [Retail Pharmacy]='PSMAS', '00001', [Doctor Number])) as [Doctor Number]

Anonymous
Not applicable
Author

With Isnull() , you dont required to write If() again...

It should be like this

if(len(trim([Doctor Number])) = 0 or IsNull([Doctor Number]),