Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
souadouert
Specialist
Specialist

set analysis with p() funciton

Hello,

I Used this expression to count client , with activ statut IN 20171229


COUNT(DISTINCT {<CLIENT_ID=P({<statut_client={'actif'},DATE={'20171229'}>}),DATE={$(DATE_SELECTION)}>}CLIENT_ID)


so NOW I NEED  to modify this expressin , I want to replace DATE={'20171229'} with  the MIN(DATE) between

20171229 and DATE_SELECTION

1 Solution

Accepted Solutions
sunny_talwar

So did this work?

Count(DISTINCT {<CLIENT_ID=P({<statut_client={'actif'}, DATE = {"$(=RangeMin(20171229, DATE_SELECTION))"}>}), DATE={$(DATE_SELECTION)}>} CLIENT_ID)

View solution in original post

4 Replies
sunny_talwar

This

Count(DISTINCT {<CLIENT_ID=P({<statut_client={'actif'}, DATE = {"$(=RangeMin(20171229, DATE_SELECTION))"}>}), DATE={$(DATE_SELECTION)}>} CLIENT_ID)

Is your DATE field in number format?

souadouert
Specialist
Specialist
Author

Hello sunny ,

Yes in number format

sunny_talwar

So did this work?

Count(DISTINCT {<CLIENT_ID=P({<statut_client={'actif'}, DATE = {"$(=RangeMin(20171229, DATE_SELECTION))"}>}), DATE={$(DATE_SELECTION)}>} CLIENT_ID)

souadouert
Specialist
Specialist
Author

Thank you sunny