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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
nareshthavidishetty
Creator III
Creator III

Year format

I have year format as 5024 ,5048,5049.I need to convert it as 'YYYY'.

11 Replies
sunny_talwar

Try this:

Year(Date(AddYears(Date(Date#('19' & Right(FCFSDT,6),'YYYYMMDD'), 'DD/MM/YYYY'), 100 * Left(FCFSDT,1)), 'M/D/YYYY')) as Year

Peter_Cammaert
Partner - Champion III
Partner - Champion III

Maybe a bit simpler:

...Year(Date#(19000000+FCFSDT, 'YYYYMMDD')) AS Year, ...