Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

the max method in set analysis

Hi all members

i have one problem

i use like this exemple

Task

DateTask

T1

13/12/2015

T1

01/12/2015

T1

03/10/2014

T2

01/01/2016

T2

03/01/2016

T3

06/01/2016

i want to load the max date for any Task like

Task

DateTask

T1

13/12/2015

T2

03/01/2016

T3

06/01/2016

i used a variable vMaxDate=date(max(DateTask)) ( i wrote =  )

but the result is not OK, when i select one row in chart table i get the good value ,but in the first display for all values it desplay one values of all rows

Tache

Date

T1

13/01/2016

T2

13/01/2016

T3

13/01/2016

how can i do

thanks all

10 Replies
Not applicable
Author

i used like this script

load 

Distinct Task,

(MakeDate(1900+left(DateTask,3))+mid(DateTask,4)-1) as DateTask ;

SQL SELECT

Tache as Task,

date as DateTask,

FROM "database".

MK_QSL
MVP
MVP

Try

Task as Dimension

Expression

FirstSortedValue(DateTask, -Aggr(Max(DateTask),Task))

Not applicable
Author

Does not work

MK_QSL
MVP
MVP

Provide sample app

MK_QSL
MVP
MVP

Create a Straight Table

Dimension

Task

Expression

Date(Max(DateTask))

nilesh_gangurde
Partner - Specialist
Partner - Specialist

Hi

Use this

load

Distinct Task,

(MakeDate(1900+left(DateTask,3))+mid(DateTask,4)-1) as DateTask ;

SQL SELECT

Tache as Task,

Max(date) as DateTask,

FROM "database" Group By Tache;

OR

In the Straight table take dimension as Task and expression as Aggr(Max(DateTask),Task)

Regards,

Nilesh

miguelbraga
Partner - Specialist III
Partner - Specialist III

Hi there,

Check my solution.

Screenshot_1.png

Regards,

MB

senpradip007
Specialist III
Specialist III

Look at this.

sunny_talwar

Seems to be working, what isn't working for you?

Capture.PNG