Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
apthansh
Creator
Creator

Sum with distinct ID

Looking for equivalent of below script in load script.Is it possible.

sum(aggr(sum(DISTINCT [Seats]), [key]))

Than you.

3 Replies
its_anandrjs

This is


Load DISTINCT

[key],

Sum([Seats])

From Source

Group By [key];

its_anandrjs

You can give name to sum field as well

Load DISTINCT

[key],

Sum([Seats]) as SeatsSum

From Source

Group By [key];

dinuwanbr
Creator III
Creator III

Try This

Load

Key,

count(distinct [Seats]) as SeatsSum

from [Source]

group by Key;

Rgds,

Tharindu