Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
mokitsu61
Creator
Creator

Getting date as timestamp by using YearStart()

Hi,

I'm trying to get first date of year as Timestamp.

YearStart() function return Date as text, and I can't find converting that value as Timestamp.

LET $value = YearStart('10-10-2018');  // Returns '01-01-2018', But I need a value as Timestamp.

Does any one know how to convert Date value which was returned from YearStart() to value in Timestamp?

Thanks.

1 Solution

Accepted Solutions
mokitsu61
Creator
Creator
Author

Hi,

It's fixed by following.

LET varDateMin = Num(YearStart($(DateValue))));

Thanks.

View solution in original post

2 Replies
sunny_talwar

May be this

LET $value = TimeStamp(YearStart('10-10-2018'));

or

LET $value = TimeStamp(YearStart('10-10-2018'), 'MM/DD/YYYY hh:mm:ss TT');

mokitsu61
Creator
Creator
Author

Hi,

It's fixed by following.

LET varDateMin = Num(YearStart($(DateValue))));

Thanks.