Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Announcements
Announcement: Certain actions are currently causing a Page Not Found error. This is a known issue and we are working with the platform vendor to investigate and resolve it.
Highlighted
Not applicable

Max(Date) on Graphic

Hi,

I'm new to Qlikview and try to do one thing creating a graphic - simple table

With such records :

account, action, date

I want to retrieve only the last actions by account (using max(date)). So I use expression :

Max ([Date])

but it doesn't work, Can you help me?

Thanks in advance.

6 Replies
Partner
Partner

Max(Date) on Graphic

Hi,

Try to use Calculated dimension =if(Date=max(total Date),Date).

And check Suppress When Value Is Null

BR,

Konstantins

Not applicable

Max(Date) on Graphic

Thanks Konstantins.

Here, it's only retrieve the last action. I'd want the last action per account, any idea? The equivalent in SQL :

SELECT ACCOUNT,

ACTION,

MAX (DATE)

FROM TABLE

GROUP BY ACCOUNT, ACTION

Partner
Partner

Max(Date) on Graphic

So, where is the problem? This SQL query looks OK. What is the result of it? And which graphic you want to create?

Not applicable

Max(Date) on Graphic

My Last SQL is my objective.

issue you gave me would be the equivalent SQL :

SELECT ACCOUNT,

ACTION,

DATE

FROM TABLE

WHERE DATE = (SELECT MAX(DATE) from TABLE)

... which is not my requirement.

Partner
Partner

Max(Date) on Graphic

I've tested your first SQL. It works. You said that MAX(DATE) doesn't work. Where? In the script or in the object?

Partner
Partner

Max(Date) on Graphic

The good practice is to read all the data and to show in the object (to calculate) only necessary in this object.

In your case I would recommend to read from SQL all records. Then in the object use calculated dimension as I mentioned in my 1st post.

BR,

Konstantins