Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Convert Mon'YY to MM/DD/YY.

Hi All,

Convert Mon'YY  to MM/DD/YY.

Ex: April'15 to 04/01/15.

Thanks,

Krishna

   

Month
April'15
Aug'15
Dec'15
Feb'16
Jan'16
July'15
June'15
May'15
Nov'15
Oct'15
Sept'15
12 Replies
Chanty4u
MVP
MVP

try

=Date(Date#(Month,'MMM''YY'), MM/DD/YY) as NewMonth

awhitfield
Partner - Champion
Partner - Champion

Have you posted the wrong xlsx, there are no dates in it!

Andy

sunny_talwar

I don't see Month field in your attached Excel

Capture.PNG

Anonymous
Not applicable
Author

Hi Sunny,

I'm Sorry. Just now I attached 1.Xlx. Please delete  attached file.

Thanks,

Krishna

Kushal_Chawda

try this

date(monthstart(date#(purgechar(Month,chr(39)),'MMMYY')),'MM/DD/YY') as Month

tresesco
MVP
MVP

Alt(Date(Date#(String2, 'MMMM''YY'), 'MM/DD/YY'),

          Date(Date#(String2, 'MMM''YY'), 'MM/DD/YY')) as Date



Note: Single quote twice (in red)


Replace 'String2' with your field name.


Untitled.png

senpradip007
Specialist III
Specialist III

Try like

LOAD *,

  MakeDate(Year(New), Month(New), 1) as New1;

  

LOAD *,

date#(replace(Month, Chr(39), ''), 'MMMYY')  as New Inline [

Month

Apr'15

Aug'15

Dec'15

Feb'16

Jan'16

Jul'15

Jun'15

May'15

Nov'15

Oct'15

Sep'15

];

sunny_talwar

Here is another option:Capture.PNG

SET MonthNames='Jan;Feb;Mar;April;May;June;July;Aug;Sept;Oct;Nov;Dec';

Table:

LOAD Date(Date#(Month, 'MMM''YY'), 'MM/DD/YYYY') as MonthYear,

  Month

FROM

[1.xls]

(biff, embedded labels, table is Sheet1$);



Chanty4u
MVP
MVP

Did u try my expression?