Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Save the Date: QlikWorld Online, June 24-25, 2020. Free global virtual event for data integration and data analytic gurus. Register Today
Highlighted
Contributor III

Restrict the dates in load script

Hi All,

Could someone help me to display only the

A:

ID, DATE, MESSAGE

1,10/11/2012 12:00:56, YES

1,10/11/2012 12:04:43, NO

1,10/11/2012 13:10:02,YES

2,113/11/2012 13:11:02,YES

2,11/11/2012 13:15:02,YES

2,12/11/2012 14:20:02,YES


And I want to create something like this:

ID, DATE, MESSAGE

1, 10/11/2012 13:10:02, YES,

2, 12/11/2012 14:20:02, YES

I need only the last time when ticket was updated to be displayed in a streight table.

I tried to use the Max(DATE) in the chart to sort them but I want to restrict the data from the load script. Any advises?

Thansk in advance!

C

1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Re: Restrict the dates in load script

A:

LOAD * Inline

[

ID, DATE, MESSAGE

1,10/11/2012 12:00:56, YES

1,10/11/2012 12:04:43, NO

1,10/11/2012 13:10:02,YES

2,13/11/2012 13:11:02,YES

2,11/11/2012 13:15:02,YES

2,12/11/2012 14:20:02,YES

];

FirstSortedValue:

LOAD ID,

FirstSortedValue(DATE, -DATE) as Date,

FirstSortedValue(MESSAGE, -DATE) as Message Resident A Group By ID;

View solution in original post

3 Replies
Highlighted

Re: Restrict the dates in load script

May be this

Fact:

LOAD ID,

     DATE,

     MESSAGE

FROM ....

Right Join (Fact)

LOAD ID,

     Max(DATE) as DATE

Resident Fact

Group By ID;

Highlighted
Partner
Partner

Re: Restrict the dates in load script

A:

LOAD * Inline

[

ID, DATE, MESSAGE

1,10/11/2012 12:00:56, YES

1,10/11/2012 12:04:43, NO

1,10/11/2012 13:10:02,YES

2,13/11/2012 13:11:02,YES

2,11/11/2012 13:15:02,YES

2,12/11/2012 14:20:02,YES

];

FirstSortedValue:

LOAD ID,

FirstSortedValue(DATE, -DATE) as Date,

FirstSortedValue(MESSAGE, -DATE) as Message Resident A Group By ID;

View solution in original post

Highlighted
Contributor III

Re: Restrict the dates in load script

Thanks for it, works now using this