Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

avinsingh
New Contributor II

Set Analysis

Hi Team,

Need Help. I am trying to extract total transaction between a defined date range. But i am not getting it.

For example Start date=5-Nov-2017

Start date=12-Nov-2017

For this i have tried writing the set analysis but it's not correct.

set vStartDate= date#('05/11/2017','DD/MM/YYYY')

set vEndDate= date#('05/11/2017','DD/MM/YYYY')

count({<TransactionDateTime={">=$(vStartDate)<=$(vEndDate)"}>} distinct TransactionSlip)

Can some help me in correcting it.

Regards,

Avinash

5 Replies
Employee
Employee

Re: Set Analysis

The variable are extracted as text in your set modifier. Please adjust your variables to match the date format used in your data.

avinsingh
New Contributor II

Re: Set Analysis

Hi Toni,

I tried correcting the format.but still bad luck. Can you suggest any alternate method.

Regards,

Avinash

devarasu07
Honored Contributor II

Re: Set Analysis

Hi,

may be this?

Count({<TransactionDateTime = {">=$(=Date(vStartDate)<=$(=Date(vEndDate)"} >} distinct TransactionSlip)

if it's not working, can you share your app with  mock data.

Thanks,

Deva

Employee
Employee

Re: Set Analysis

Your variable definitions use SET, please change these to LET.

Re: Set Analysis

May be this

Count({<TransactionDateTime={">=$(=vStartDate)<=$(=vEndDate)"}>} distinct TransactionSlip)

Community Browser