Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
tamilarasu
Champion
Champion

MaxString is not working in advanced set analysis

Hi All,

I have below MaxString expression which is working fine for each line.

= Maxstring( {< %BILLINGDOC=, KONV.KSCHL={'ZVSH'} >} KONV.KNUMH) 

Now, I have to find max KNUMH value (for that I used above maxstring  function) and sum up the respective KBETR values for each MEL numbers. So, I am trying to apply the same in advance set analysis which is not working.

= Sum (  {<


KONV.KNUMH={"= Maxstring( {< %BILLINGDOC= ,KONV.KSCHL={'ZVSH'}>} KONV.KNUMH)" }

         >}


KONV.KBETR)


In my case it should show 0 i.e KBETR is 0 for for the KNUMH - 0322567585.


I think Maxstring function is not working in advanced set analysis. Any help or guidance is appreciated.

Capture.PNG

Note:  Please do not ask me to upload the application which is not possible,

Edit: I have uploaded sample document

20 Replies
sunny_talwar

My bad, can you try this (removed the negative sign for the Rank) because the rank for max value is 1 and you need to pick the lowest rank

=FirstSortedValue({<%BILLINGDOC= ,KONV.KSCHL={'ZVSH'}>} Aggr(Sum({<%BILLINGDOC= ,KONV.KSCHL={'ZVSH'}>} KONV.KBETR), MARA_ENHANCED.NORMT, KONV.KNUMH), Aggr(Rank(KONV.KNUMH), MARA_ENHANCED.NORMT, KONV.KNUMH))