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

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Where clause in table with multiple fields using LastValue()

Hallo QV geniuses,

I have s script like this:

Table1:

Load UID,

A,

B,

C,

D,

E,

F,

date_modified

FROM excel...;

Table2:

Load UID,

LastValue(A) as A_1,

LastValue(B) as B_1,

LastValue(C) as C_1,

LastValue(D) as D_1,

LastValue(E) as E_1,

LastValue(F) as F_1

Resident Table1

where not isNull(UID)

Group by UID

Order by date_modified;

Since it is ordered by date_modified, it means my LastValue() is the latest. But my problem is: If the LastValue() is NULL, I want to get the previous NON-NULL value.

I tried to put a:

where not isNull(UID) and not isNull(A) and not isNull(B) and not isNull(C) and not isNull(D) and not isNull(E) and not isNull(F)

But it doesn't work. Can you help me on this? Thanks a lot.

1 Reply
pablolabbe
Partner Ambassador
Partner Ambassador

Hi,

Did you solved it ?

Did you find a solution to your question? Mark the solution as accepted and if you found it useful, press the like button! | Follow me on Linkedin