Qlik Community

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

cancel
Showing results for 
Search instead for 
Did you mean: 
kushalthakral
Creator III
Creator III

Concat values for only flag with minimum value

Hi All

i have a requirement where i need to concat values where we have minimum flag associated with the Id values like in below table 

IdSub IDFlg
AA11
AA22
BB12
CC12

 

For Id A, i have two values one for flg 1 and one flg 2, in case of Id B i have only one value of flg i.e 2 

So i need to concat A1,B1 and C1 based on minimum values of flag for associated Id's

I hope my question is making sense

 

Thanks in advance

 

Kushal

 

1 Solution

Accepted Solutions
rubenmarin

Hi, if possible i would flag the min values of each id in script so you only need:

Concat({<MinFlag={1}>} [Sub ID])

If not I think you will need an aggr and an if, like: =concat(Aggr(If(Flg=Min(TOTAL <Id> Flg), [Sub ID]),Id,Flg) ,',')

View solution in original post

2 Replies
rubenmarin

Hi, if possible i would flag the min values of each id in script so you only need:

Concat({<MinFlag={1}>} [Sub ID])

If not I think you will need an aggr and an if, like: =concat(Aggr(If(Flg=Min(TOTAL <Id> Flg), [Sub ID]),Id,Flg) ,',')

View solution in original post

kushalthakral
Creator III
Creator III
Author

Thanks, that is what I was looking for

Thanks for your efforts and Help

 

Cheers 

Kushal