Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I need to get max value of alphanumeric field, can any one help assist the same.
Please find attached screen shot.
Expression : MaxString({<ACTIVE_ACTION_Flag = {1}>}total [End ID])
Thanks
Santharubban KS
May be this
Aggr(If(HISTORIZIED_Flag = 0,
If(SubField([End ID], '.', -1) = Max(TOTAL <[GPID Number]> SubField([End ID], '.', -1)), [End ID]),
If(PurgeChar(SubField([End ID], '_', -1), 'H') = Max(TOTAL <[GPID Number]> PurgeChar(SubField([End ID], '_', -1), 'H')), [End ID])), [GPID Number], [End ID])
May be this
Aggr(If(SubField([End ID]), '.', -1) = Max(TOTAL <[GPID N...]> SubField([End ID]), '.', -1)), [End ID]), [GPID N...], [End ID])
if the number are always separable by dot them try like below
LOAD GPID,
[Program ID],
[End ID],
subfield([End ID],'.',2) as Number
FROM QVD;
Now on front end, below expression should work
=max(total <GPID>Number)
Thanks Sunny.
for Active action i am good but for Historized actions i am not able to get .
Not sure I understand?
Hi Sunny,
If you see my attachment, I have 2 different action one is Active and or this History action. For Active an I am getting right result but for History action i am not get correct answer as i marked in my attachment.
Exp:
Aggr(if(HISTORIZIED_Flag = 1 and SubField(SubField([End ID],'_',-1),'.',-1) = (Max(SubField(SubField([End ID],'_',-1),'.',-1))), [End ID] ), [GPID Number],[End ID])
Can you post your application?
please find attached sample applications
May be this
Aggr(If(HISTORIZIED_Flag = 0,
If(SubField([End ID], '.', -1) = Max(TOTAL <[GPID Number]> SubField([End ID], '.', -1)), [End ID]),
If(PurgeChar(SubField([End ID], '_', -1), 'H') = Max(TOTAL <[GPID Number]> PurgeChar(SubField([End ID], '_', -1), 'H')), [End ID])), [GPID Number], [End ID])
Thanks Sunny I got it