Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
richard_chilvers
Specialist
Specialist

Loading just the max record in each group

Hi

This seems a simple issue, but I cannot find the solution on here !

My table has the following fields per record:

Index, date, field1, field2

For each value of Index, I want to load just the record with MAX(date).

I believe   LOAD Index, MAX(date) from table group by Index    would work.

But how do I include field1 and field2 ?

Thanks.

1 Reply
Gysbert_Wassenaar

Left join it with the load of all fields:

load Index, max(date) as date from table group by Index;

left join load Index, date, field1, field2 from table;


talk is cheap, supply exceeds demand