Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikWorld, June 24-25, 2020. Free virtual event for DI and DA gurus. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator II
Creator II

Display the oldest date in a text object based on values

Hi,

I have a sample set of data values as shown below. My requirement is to dynamically display only the date of the oldest overdue work# in a text object. In this case it would be 2/14 or Feb 2014 .  

Thanks for the help!

Tags (1)
1 Solution

Accepted Solutions
Highlighted
Creator III
Creator III

Re: Display the oldest date in a text object based on values

Hi Ashwin,

not sure I totally understand but try this.

1. In your load script, create new field with actual date, something like that

     ...

     MakeDate( 2000+ num(right([MM/YY],2)), left([MM/YY], Index([MM/YY],'/',1)-1 )) as workdate,

     ....

2. Then create a textbox with this expression

=min({$<Overdue_flag={1}>} workdate)

This will output 02/01/2014

is this what you have in mind?

View solution in original post

3 Replies
Highlighted
Creator III
Creator III

Re: Display the oldest date in a text object based on values

Hi Ashwin,

not sure I totally understand but try this.

1. In your load script, create new field with actual date, something like that

     ...

     MakeDate( 2000+ num(right([MM/YY],2)), left([MM/YY], Index([MM/YY],'/',1)-1 )) as workdate,

     ....

2. Then create a textbox with this expression

=min({$<Overdue_flag={1}>} workdate)

This will output 02/01/2014

is this what you have in mind?

View solution in original post

Highlighted
Creator II
Creator II

Re: Display the oldest date in a text object based on values

Thanks!!! That will work.


I guess I was wondering if there was a way to accomplish this without having to make changes to the script with only the given data. That may not be possible.

Highlighted
Creator III
Creator III

Re: Display the oldest date in a text object based on values

it is possible but your expression will be more complicated than it needs to be and you should strive to do all transformations you can in your load script.

Remember that you normally want to spend 60% of your time on a data model and 40% on the visualizations - data model is the key!