Qlik Community

Qlik Education Discussions

Discussion Board for collaboration related to Qlik Education.

turodionova
New Contributor II

Sales Data for max Date

Hi!

I need to create report with sales data by customers related to the latest sales date for each.

Yellow lines in the table below are what i need to extract.

Capture.PNG.png

I use an expression: aggr(max(Date),[Customer]) and get right date for every Customer.

Then i try to use this expression for sales data: sum({$<Date={"=aggr(max(Date),[Customer])"}>}Sales) 

and get a wrong result.

Thanks in advance.

10 Replies
MVP
MVP

Re: Sales Data for max Date

FirstSortedValue(Sales,-Date)

Employee
Employee

Re: Sales Data for max Date

Was it exactly what you were looking for Tamara? Did it work?

turodionova
New Contributor II

Re: Sales Data for max Date

Hi, Agis!

It does not work unfortunately in my case. I guess some grouping is

needed?

Kind regards

Tamara Rodionova

Colgate-Palmolive Russia.

Senior Sales Analyst

Office phone +7495 937 11 00 (ext. 2-822)

MVP
MVP

Re: Sales Data for max Date

Provide few more data which showing that this is not working.... This should work on the sample data you have provided.

turodionova
New Contributor II

Re: Sales Data for max Date

Sales - ,

Date - Дата

Kind regards

Tamara Rodionova

Colgate-Palmolive Russia.

Senior Sales Analyst

Office phone +7495 937 11 00 (ext. 2-822)

ecolomer
Honored Contributor II

Re: Sales Data for max Date

here you have an example for this

MVP
MVP

Re: Sales Data for max Date

Can you create little dummy data and pass to us? Your application is difficult to understand..

turodionova
New Contributor II

Re: Sales Data for max Date

Manish, your expression works in a model with dummy data, so the issue is

in my application.

I will try to identify, thanks for your help.

Kind regards

Tamara Rodionova

Colgate-Palmolive Russia.

Senior Sales Analyst

Office phone +7495 937 11 00 (ext. 2-822)

turodionova
New Contributor II

Re: Sales Data for max Date

Manish, it worked, but as soon as i concatenate additional value, it

stopped working.

Kind regards

Tamara Rodionova

Colgate-Palmolive Russia.

Senior Sales Analyst

Office phone +7495 937 11 00 (ext. 2-822)

Community Browser