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

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to compare date

Hi,

How to use Analysis set to compare date:

I have two datetime parameters: Entered datetime and Completion Datetime. I want to get the Amount aggregation based on the datetime between Entered and Entered +7, I use this one, but it doe not work.

Sum({$<CompletionDate={$(<=DateEntered+7)}>}Amount)

Could you help me out? Thanks.

5 Replies
sparur
Specialist II
Specialist II

Hello, Isaac

try this:

Sum({$<CompletionDate={">=$(vDateEntered)<=$(=$(vDateEntered)+7)"}>}Amount)

where vDateEntered - variable with you value.

Not applicable
Author

Hi,

I need to use DateEntered as a field not Variable. Because I will put a dimension into chart.

And I have tested, this works:

sum({$<CompletionDate={"<=$(=(DateEntered))"}>}amount) ,

But how can I add 7 days into it.

Not applicable
Author

Hi Isaac,

please check the format of your fields "CompletionDate" and "DateEntered+7".

Maybe you are comparing a string with a number.

Are you able to upload a short example of your data (*.qvw hopefully)?

Rainer

sparur
Specialist II
Specialist II

Can you post a small qvw example?

Not applicable
Author

Hi,

My Datetime format is '2010/01/01 00:00:00'