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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
shree909
Partner - Specialist II
Partner - Specialist II

summation of date

Hi i have a start date and end date

i want to do the substraction from end date to start date

my expression was

=date((start_date)-(end date),'MM_DD_YYYY')

when i do it shows  01/15/1900.

even i unchecked the force 0 on axis tab,

i also changed the fomat in the number as date.

can anyone had this type of issue..

7 Replies
CELAMBARASAN
Partner - Champion
Partner - Champion

I don't get what you try to achieve in this?

Do you need number of days?

shree909
Partner - Specialist II
Partner - Specialist II
Author

i need date,month and year

i am trying to built a gantt chart , where i have a start date and end date..and a dimension..

so my first expression consits for  (start date - end date)

this range i want to show it as  bar and also the end date at the end of the bar...

CELAMBARASAN
Partner - Champion
Partner - Champion

To tell exactly it will be a number of days right?

Simply you can specify as (EndDate - StartDate)

shree909
Partner - Specialist II
Partner - Specialist II
Author

i did the same thing but it shows year as 1900..

why would that show up then

CELAMBARASAN
Partner - Champion
Partner - Champion

Don't use date()

Use simply as Floor(EndDate-StartDate)

or

interval(EndDate-StartDate,'d')

Hope it helps

MayilVahanan

Hi

Try like this

=Num(EndDate) - Num(StartDate)

or

Interval()

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
shree909
Partner - Specialist II
Partner - Specialist II
Author

thanks for  the reply but i want to show the end date on the bar.

for that i  caluculated on the show max value when i expanded the + sign but there it show   date as 1900

even i formated  like date((enddate),'MM-DD-YYYY').

is there a way it can be shown