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

Announcements
Independent validation for trusted, AI-ready data integration. See why IDC named Qlik a Leader: Read the Excerpt!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Default Date in Calendar Object

HI,

I have a Calender object. I need to show the default date the the last day of the month. Based on the value in the calendar object, I need to derive date difference for two fields in input sheet.

Attached is the one what I have done so far.

I have created a variable as vDate = Date(month(now())). Assigned this variable to the calender object max value.

But the date initial date difference is some DateNum field with decimal places. (See the Date Diff1 and Date Diff2).

When I change the date in the calendar object, then values changes in the date diff fields. This time it gives actual days of date difference with decimal places.

My requirement is to get only the days in difference not with the decimal places. And also the initial date difference which shows a DateNum field, it should also show the actual days in difference.

Thank you.

1 Solution

Accepted Solutions
MayilVahanan

Hi

PFA

Are you need this?

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.

View solution in original post

5 Replies
angelaecheverri
Creator
Creator

Try use Ceil in this way you dont have decimals....

Ceil(Date($(vDate)))-Ceil(Date(BATCH_DATE))

Not applicable
Author

Date - Date, shouldn't it give an integer?

I can use, Ceil / Floor, But if I delete the decimal value in the variable once by going through variable setting, then I dont get the decimal for any other date selection.

MayilVahanan

Hi

PFA

Are you need this?

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
angelaecheverri
Creator
Creator

What is PFA?

MayilVahanan

Hi

PFA -> Please Find Attachment

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.