Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

omyahamburg
Contributor II

find highest value

Hi all

Seems my head is not the best today.

I am trying to find the highest value in a table. In this case it is the value in month 10.

IDMonthValue
Item017.279.389
Item027.621.106
Item037.928.659
Item048.374.085
Item057.582.951
Item068.461.163
Item078.800.933
Item088.578.971
Item098.505.260
Item109.313.773
Item119.109.731
Item128.673.098

The desired result should look like this:

IDMonthValue
Item109.313.773

I tried with max, but failed.

Can somebody give me an idea for a formula ?

Thanks in advance.

Joerg

7 Replies
jagannalla
Valued Contributor III

Re: find highest value

Hi,

Take Dimension as ID and expression as =firstsortedvalue ( Value, -Month) 

Otherwise go like this Take Dim as ID, Month and expression as =Sum({<Month={$(=Max(Month))}>}Value)


Cheers!!

Jagan

omyahamburg
Contributor II

Re: find highest value

Dear Jagan.

Thanks. I will try when I am back in office.

Cheers.

Joerg

omyahamburg
Contributor II

Re: find highest value

Dear Jagan

I think rank function will better fit my needs.

Thank you for helping.

Cheers

Joerg

Gabriel
Valued Contributor III

Re: find highest value

Hi Joerg,

Can I suggest you try FirstSortedValue() function.

Let me know if it works

Regards

er_mohit
Honored Contributor II

Re: find highest value

hii

see attached file

Not applicable

Re: find highest value

    hi

try it

LOAD

only(id),

max(value) as maxvalue,

FirstSortedValue(mon,-value) as monthno.;

LOAD id,

         mon,

         value

FROM

C:\test41.xlsx

(ooxml, embedded labels, table is Sheet1);


omyahamburg
Contributor II

Re: find highest value

Hi

Thanks a lot. This helps me.