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: 
raadwiptec
Creator II
Creator II

expressn

i have a tricky situation where i need to sum diffierent values in expression

sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},[Code] = {'91'},Entity = {'CRKNM'}  >}Amount_Euro)

+

sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},[Code] = {'91'},Entity = {'LMGCR'}  >}Amount_Euro)

+

sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},

 = {'91'},Entity = {';KOPDD'}  >}Amount_Euro)

the above is not working...any suggestion

3 Replies
m_woolf
Master II
Master II

If you are getting a null result, it could be because one of the three sub expressions is null.

try using Rangesum:

Rangesum(sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},[Code] = {'91'},Entity = {'CRKNM'}  >}Amount_Euro),sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},[Code] = {'91'},Entity = {'LMGCR'}  >}Amount_Euro).sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},

 = {'91'},Entity = {';KOPDD'}  >}Amount_Euro))

Anonymous
Not applicable

Hi Raad,

In the 3rd set expression please remove the semicolon before the Entity value. Entity = {';KOPDD'}  The expression would be like below,

sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},[Code] = {'91'},Entity = {'CRKNM'}  >}Amount_Euro)

  +

sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},[Code] = {'91'},Entity = {'LMGCR'}  >}Amount_Euro)

  +

sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},

 = {'91'},Entity = {'KOPDD'}  >}Amount_Euro)

Thanks,

Sarat.K

vishsaggi
Champion III
Champion III

Why don't you use Entity only once like below:

= sum({<Source={'SAP'}, Category = {'Finance'},Object = {'23'},

 = {'91'},Entity = {'CRKNM', 'LMGCR', 'KOPDD'}                 >}Amount_Euro)