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: 
nvijay5757
Creator
Creator

Pivot table Max date

Hi ,

in pivot table how to take max date

ex: 

nvijay5757_0-1659885415186.png

in original ppap column as end_date. in this some rows are showing two to three dates how to take max date. if i apply MAX(date) not working. 

LOAD Distinct site_code,
Concat(DISTINCT part_description,', ') as Part_descriprion_new,
date(Max(end_date), 'YYYY-MM-DD') as end_date, 1 as date_flag
Resident Input Group By site_code;

i have written in script but all is grouping then it is showing only one site code. help me thanks.

4 Replies
BrunPierre
Partner - Master II
Partner - Master II

Maybe like this

TEMP:
LOAD Distinct site_code,
Part_descriprion_new,
end_date,
1 as date_flag
Resident Input;

FINAL:
LOAD site_code,
date_flag,
Concat(DISTINCT part_description,', ') as Part_descriprion_new,
Max(Date(end_date),'YYYY-MM-DD') as end_date
Resident TEMP
Group By site_code,date_flag;

DROP Table Input;

nvijay5757
Creator
Creator
Author

Hi thanks for your reply,

above load i have used      Left Join( Input).

so if take resident then remaining cols missing.

BrunPierre
Partner - Master II
Partner - Master II

@nvijay5757 Sorry, I didn't quite catch what you said.

BrunPierre
Partner - Master II
Partner - Master II

@nvijay5757 Is your question answered?