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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

help in set analysis expression

Hi all,

i have this data

QuartershowenQlastData
1Qx4100
2Qy140
3Qz230
4Qs350

the field that's showen in the document (the field i select from it) is 'Showen'

i want to write ana expression that's when i select from field showen it gives me the data of the Quarter=Qlast

i mean if i select Qx in this case Qlast=4 so i want te expression to give me the data when Quarter=4 Which is 50

another example: if i select Qy, Qlast =1 so i want to get the data when Quarter=1 which is 100

and so on

how to do that?

Labels (1)
3 Replies
swuehl
Champion III
Champion III

Maybe like

=Only({1<Quarter = {$(=Only(Qlast))}>} Data)

Not applicable
Author

Thanks Swuehl, but it didn't work

also, i have to use sum on the data because the original table i have has multiple rows, the example above is just to clarify the idea

AbhijitBansode
Specialist
Specialist

Use below :

I have loaded sample data with inline load.

Temp_Tlb:

LOAD * INLINE [

Quarter,showen,Qlast,Data

1,Qx,4,100

2,Qy,1,40

3,Qz,2,30

4,Qs,3,50

];

Right Join

Res_Tlb:

LOAD Quarter as Qlast,

     Data as Temp_Data

Resident Temp_Tlb;

In Expression use sum(Temp_Data) to get the desired result.

Regards,

Abhijit B