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

Announcements
Learn how to migrate to Qlik Cloud Analytics™: On-Demand Briefing!
cancel
Showing results for 
Search instead for 
Did you mean: 
JMAROUF
Creator II
Creator II

Two lines at the same line

Hi,

i have an issue to show two transactions at the same line, i want to show the first and the second transactions of the max dates  at the same line, it's possible? here's the model and the result desired:

 

JMAROUF_1-1634919493426.jpeg

 

The output desired:

JMAROUF_2-1634919622455.jpeg

the invested_position of the max date and position investor of the max date, can any one help please?

Labels (1)
1 Solution

Accepted Solutions
JMAROUF
Creator II
Creator II
Author

I have solved the problem by duplicating the fact and linked it to investors as invested and adding a flag to the transaction fact (max_date by invested_investor) and adding the two formulas in dimension and expression with excluding null values:

=IF(max_date=date and PFGI=1 AND PFPP=1,ID_INVESTED)

=max(IF(max_date=date and PFGI=1 AND PFPP=1,POSITION))

View solution in original post

1 Reply
JMAROUF
Creator II
Creator II
Author

I have solved the problem by duplicating the fact and linked it to investors as invested and adding a flag to the transaction fact (max_date by invested_investor) and adding the two formulas in dimension and expression with excluding null values:

=IF(max_date=date and PFGI=1 AND PFPP=1,ID_INVESTED)

=max(IF(max_date=date and PFGI=1 AND PFPP=1,POSITION))