Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

Create Date from String

Hey All,

I have tried a bunch of things, but am unable to convert the TimeCardDate (DD-MON-YY) from a string to a date field.

Any help would be appreciated - here is the format of the data:

TimeCardDate
02-OCT-16
09-OCT-16
16-OCT-16
18-SEP-16
23-OCT-16
24-JUL-16
25-SEP-16
30-OCT-16

Thanks Vince

1 Solution

Accepted Solutions
Employee
Employee

Re: Create Date from String

Please try this:

SET MonthNames='jan;feb;mar;apr;may;jun;jul;aug;sep;oct;nov;dec';

LOAD Date(Date#(lower(TimeCardDate),'DD-MMM-YY')) as TimeCardDate Inline [

TimeCardDate

02-OCT-16

09-OCT-16

16-OCT-16

18-SEP-16

23-OCT-16

24-JUL-16

25-SEP-16

30-OCT-16

]

2 Replies
Employee
Employee

Re: Create Date from String

Please try this:

SET MonthNames='jan;feb;mar;apr;may;jun;jul;aug;sep;oct;nov;dec';

LOAD Date(Date#(lower(TimeCardDate),'DD-MMM-YY')) as TimeCardDate Inline [

TimeCardDate

02-OCT-16

09-OCT-16

16-OCT-16

18-SEP-16

23-OCT-16

24-JUL-16

25-SEP-16

30-OCT-16

]

Not applicable

Re: Create Date from String

worked like a charm - thank you

Community Browser