Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
Can you tell me how can I count the days between two dates ?
I want to create a chart with opened cases and I have to create some dimensions in days.
<7 days 14-14 days 14-30 days 30-90 days.
Similar to this chart.
And I don't have any ideas how to do this. Can you give me a clue ?
Thanks!
Use a calculated dimension with an if condition like below
if (Interval(DateField2 - DateField1,'D')<7,'<7 days',
if(Interval(DateField2 - DateField1,'D')>7 and Interval(DateField2 - DateField1,'D')<14,'7-14 days',
if(Interval(DateField2 - DateField1,'D')>14 and Interval(DateField2 - DateField1,'D')<30,'14-30 days',
if(Interval(DateField2 - DateField1,'D')>30 and Interval(DateField2 - DateField1,'D')<90,'30-90 days','>90 Days'))))
hth
Sasi
Hi,
Can you share your qvw file or sample file.
=fabs(Date(EndDate,'DD/MM/YYYY')) - fabs(Date(StartDate,'DD/MM/YYYY'))
Is not working.
Use a calculated dimension with an if condition like below
if (Interval(DateField2 - DateField1,'D')<7,'<7 days',
if(Interval(DateField2 - DateField1,'D')>7 and Interval(DateField2 - DateField1,'D')<14,'7-14 days',
if(Interval(DateField2 - DateField1,'D')>14 and Interval(DateField2 - DateField1,'D')<30,'14-30 days',
if(Interval(DateField2 - DateField1,'D')>30 and Interval(DateField2 - DateField1,'D')<90,'30-90 days','>90 Days'))))
hth
Sasi
can you share sample qvw file?
Hi try this:
If date field don't have time stamp
Date(todate)-date(frondate) as date-count
If time stamp first u have to trim the time then use above statement
Thank you ! Very helpful.
Thank you very much !