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: 
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
Champion III
Champion III

This is


Load DISTINCT

[key],

Sum([Seats])

From Source

Group By [key];

its_anandrjs
Champion III
Champion III

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