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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
trishita
Creator III
Creator III

Syntax error in my code with 'isnull'

I want to check if for a certain SURVEY ID there is any sounding correction report.

So if there is any Sounding date they will show a sounding correction report.

If there are no sounding date value it will show no sounding correction reports.

I encountered a syntax error in my following code:

if( isNull([SOUNDING_START_DATE]) ,'No Sounding Correction Report Available','Sounding Correction Report Available');

Here SOUNDING_START_DATE IS A DIMENSION

2 Replies
trdandamudi
Master II
Master II

Give a try as below:

if( Len(Trim([SOUNDING_START_DATE])))=0 ,'No Sounding Correction Report Available','Sounding Correction Report Available');

jayaramp
Contributor II
Contributor II

In addition to Raja's suggestion above you need to store the output of IF condition into a field / dimension using "AS".

if( Len(Trim([SOUNDING_START_DATE])))=0 ,'No Sounding Correction Report Available','Sounding Correction Report Available') as ReptAvailable;

Here ReptAvailable is a new dimension.

Hope this is helpful.

Thanks.