I use QV as a final user so I am not skilled in programming and how QV works, special in Set Analysis
I need to get the subtract of two dates: Date Received - Purchase Date in order to calculate the Days Passed. If the Date Received is blank, the operation must be the Actual Date (Today) - Purchase Date.
Thank you very much
Try this too
If(Interval([Date Received]-[Purchase Date],'d') > '0', Date(Interval([Date Received]-[Purchase Date]),'DD/MM/YYYY'), Date(Interval(Today()-[Purchase Date]),'DD/MM/YYYY'))
If([Date Received] = ' ', Date(Interval(Today()-[Purchase Date]),'DD/MM/YYYY'), Date(Interval([Date Received]-[Purchase Date]),'DD/MM/YYYY'))
Thank you Anil Babu.
The result of your expression is a date format 'DD/MM/YYYY' and I need it in day numbers.
The expressions provided by Marcio Arruda and Vegar Lie Arntsen are working the way I need
Thanks to all of you
I'm pleased that you found an answer to your question.
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.
You can use networkdays with two date fields. And you want to calculate all days right if so use