Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
jim_chan
Specialist

Unable to change a date format

HI there,

i have problem changing 1 of my date column to another format - mydate

i used code as such  -  Date("Start Date",'DD-MM-YYYY') as mydate , why my year become "57069" ?

date.png

Rgds

Jim

1 Solution

Accepted Solutions
qlikmsg4u
Specialist

Try this

=Date(Date#(StartDate,'YYYYMMDD'),'DD-MM-YYYY')

View solution in original post

8 Replies
qlikmsg4u
Specialist

Try this

=Date(Date#(StartDate,'YYYYMMDD'),'DD-MM-YYYY')

SreeniJD
Specialist

Hi Jim

As you know, your startdate is not in the correct date format... you have to use date# function as mentioned below..

=Date(date#("Start Date"'),'DD-MM-YYYY') as mydate

Happy to help!

Sreeni

jim_chan
Specialist
Author

Can you explain why has to put "Date#" , then (StartDate,'YYYYMMDD') ? i know this is the format 'DD-MM-YYYY'

jim_chan
Specialist
Author

I thought the "Date" is already a date function?

qlikmsg4u
Specialist

First you have to tell qlikview that your Start Date is a date field in the format of YYYYMMDD, for this you have to use Date# interpretation function next you need to format the date to your desired format using Date formatting function.

jim_chan
Specialist
Author

thank you

jim_chan
Specialist
Author

thank you

qlikmsg4u
Specialist

Welcome