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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Exists and Notexists function, can it be used in the same calculated dimension on the same field

I think i may have a syntax errrow for my below formula, which is attempting to evaluate my shipTo Customer number for the current year $(CYear) and the previous year $(PYear) to determine if the customer number is new or existing

=IF(Exists(s$(CYear)[ShipTo Customer]) and Notexists(s$(PYear)[ShipTo Customer]), 'New','Existing')

1 Reply
Not applicable
Author

Hi,

There ar no function called Notexists in QV. But you can use the logical operator Not befor Exists...

And you got the function syntax for Exists wrong...

I guess you got the New/Existing check working in the other thread...

but yes you can have it like this

if(exists([Shipto Customers],'123456') and not exists ([Shipto Customers],'129897'),'True','False')

BR

Hans