Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
tgolding
Contributor
Contributor

Include only blank or or <null> values on load

Sorrry, newbie and self taught with Qlick Sense.  Hopefully will outline correctly what is needed.

I know there have been several discussion around this and I have tried various suggested solutions but to no avail.  I am accessing data through sql file, there is one field labeled "ReversalIndicator" that includes the following values; '1', '2', and a blank or null.  I would like to only include the blank or null fields on the load script but am unable to figure how to do so.  I understand that Qlik doesn't recognize blank or null fields unless you tell it to so I have done the following;

added to set analysis

SET NullValue=',Unkown'

Added at the top of the load statement

NullAsValue ReversalIndicator;

I currently have a Where statement already included;

PaidHistory where Filldate>='date' and ReversalIndicator='<Unknown>'

Thanks for any help or guidance.

11 Replies
devarasu07
Master II
Master II

Hi,

try like this?

in your back end script add where clause like below,

load *

From Data.dbc.history where Filldate>='01/01/2016' and len(trim(ReversalIndicator))=0


note: also u can do it front end as well

like this

Calculated dimension:

if( len(trim(ReversalIndicator))<=0, result, 0)

using at set analysis level let's say u r measure is Sales

sum( {$<ReversalIndicator={"=len(trim(ReversalIndicator))<=0"}>}Sales)



load * Inline [

Name, GroupId, GroupName, ReversalIndicator, value

AMBER, 123, Green, , 5

AMBER, 123, Green, 2, 0

AMBER, 123, Green, 1, 0] where len(Trim(ReversalIndicator))=0;


Capture.JPG

Thanks,Deva

pradosh_thakur
Master II
Master II

Try this may be

LOAD *

WHERE len(trim(reversalindicator ))=0;

SQL SELECT * FROM

FROM data.dbo.PaidHistory where Filldate>='01/01/2017';

Learning never stops.