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: 
Not applicable

Set analysis & and command

Hello/Hola/Namaste/Dia Dhuit,

I wish to have a set analysis expression which has the and command where the field admission is between the two variables. After some searching, I have come up with the following but with no success. The results appear to not be filtered by the first variable.

Count({< caretype={'N'},admission = {">=$(=date((vMondayofLastWeek)))"} > + < admission = {"<=$(=date((vSundayofLastWeek)))"}, referredby = {'101021889','101030294'}  >} distinct rescare_Id)    

Any ideas?

Dank u,

Matt

1 Solution

Accepted Solutions
CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     You can use like this,

Count({< caretype={'N'},admission = {">=$(=date((vMondayofLastWeek)))<=$(=date((vSundayofLastWeek)))"},  referredby = {'101021889','101030294'}  >} distinct rescare_Id)

Or

Count({< caretype={'N'},admission = {"admission >=$(=date((vMondayofLastWeek))) And admission <=$(=date((vSundayofLastWeek)))"},  referredby = {'101021889','101030294'}  >} distinct rescare_Id)

Celambarasan

View solution in original post

3 Replies
CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     You can use like this,

Count({< caretype={'N'},admission = {">=$(=date((vMondayofLastWeek)))<=$(=date((vSundayofLastWeek)))"},  referredby = {'101021889','101030294'}  >} distinct rescare_Id)

Or

Count({< caretype={'N'},admission = {"admission >=$(=date((vMondayofLastWeek))) And admission <=$(=date((vSundayofLastWeek)))"},  referredby = {'101021889','101030294'}  >} distinct rescare_Id)

Celambarasan

stephencredmond
Partner - Specialist II
Partner - Specialist II

Hi,

Combine the two expressions in one set.  I haven't syntax checked this but it would look like this:

Count({< caretype={'N'}, admission = {">=$(=date((vMondayofLastWeek)))<=$(=date((vSundayofLastWeek)))"},  referredby = {'101021889','101030294'}  >} distinct rescare_Id)

Regards,

Stephen

Not applicable
Author

Thanks Celambarasan and Stephen. Easier solution than I thought!