Skip to main content

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Skip the ticket, Chat with Qlik Support instead for instant assistance.
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Count ID with Max(OutDate)

Hi All,

Hope someone is able to help me with this issue.

I have a table containing the below data:

3037680-132-0039000002370152018-04-10 16:08:00.0002018-05-31 16:12:42.567
3037680-132-0039000002461102018-04-10 16:08:00.0002018-08-28 13:17:09.173
3037680-132-0039000002502462018-04-10 16:08:00.0002018-05-31 16:12:42.567

I need to create a table in Qlik counting numbers of units out but using the MAX(OutDate). So the table in Qlik will show as the following:

Month/YearUnits Out

As the ID is the same I only need to count this as one unit out.

Thanks in advance.

3 Replies

First of all,

in the script create ur monthYear field as follow

Capitilize(Date(MonthStart(OutDate),'MMM-YYYY')) as MonthYear

Now in ur table, use

as dimension: MonthYear

as Measure: Count(distinct {<OutDate={"$(=max(total <ID> OutDate))"}>} PartNoOut)

Hope this helps !

Not applicable

Hi Omar,

I tried to add Capitilize(Date(MonthStart(OutDate),'MMM-YYYY')) as MonthYear into the script but this does not run due to the 'Capitilize()' section not being accepted.

Ignore it was just a spelling error. I have added everything as suggested but still get a result of 3.


It capitalize; my bad lol