Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
smilingjohn
Specialist
Specialist

convert

I have a Excel sheet , in which the month names are in text like Jan, feb , mar and so on

How do i convert this to Date ?

9 Replies
vikasmahajan

Put this in script

Date(date#(month,'YYYYMM'),'DD-MM-YYYY') as PostingDate

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
sunny_talwar

May be like this:

Month(Date#(Captialize(month), 'MMM')) as Month

Chanty4u
MVP
MVP

try

Date(Date#(Datefield,'MMMDDYYYY'),'YY-MM-DD') AS newdate

Date(Date#(Datefield,'urdatefieldformat'),'reuireddateformat') AS newdate

yadhunandhanan
Partner - Contributor III
Partner - Contributor III

Hi John,

How about this,


=Date(Date#('15-Jan-16','DD-MMM-YY'),'DD-MM-YY')


Replace '15-Jan-16' as your date field.


Hope its help.

smilingjohn
Specialist
Specialist
Author

Hi vikas  thanks


In a excel sheet i have Months vertical

Below is the example of the column under excel sheet.

ID ,Dept,Amount, Year,Jan,Feb,Mar,Apr,May....... Dec

1,  Soap, 12,  2010   23, 24,1,12,.,.,.,.,.

2 ,Cosmatics,100,, 2010 ,11,22,2

This is how i have the excel sheet , where year has no problem  only month is horizontal and in text format

How do i deal with this ,

Regards

.

Not applicable

Try thissmilingjohn



=date(Month,'DD-MM-YYYY') as DATE

sunny_talwar

You need to implement a CrossTable Load here:

The Crosstable Load

Chanty4u
MVP
MVP

use  Crosstable for that then u can create date filed as abve mentoned

vikasmahajan

After implementation of cross table , load script with  Date(date#(month,'YYYYMM'),'DD-MM-YYYY') as PostingDate

This should solve your problem

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.