Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
amit_saini
Master III
Master III

Month and Year from date

Hi Folks,

Could u plz see the attachment and tell me why year and month values are not visible.

Thanks,

AS

1 Solution

Accepted Solutions
sunny_talwar

Try this script:

LOAD *,

  month(Date) as Month,

  year(Date) as Year;

LOAD Date#(Date, 'MMM DD, YYYY') as Date, 

     Name,

     Revision

FROM

[2015-01-31-ecoReport.xlsx]

(ooxml, embedded labels, table is RawData);

View solution in original post

4 Replies
Anonymous
Not applicable

These fields Show null values in the datamodel

try year(date#(Date,'MMM DD,YYYY'))

sunny_talwar

Try this script:

LOAD *,

  month(Date) as Month,

  year(Date) as Year;

LOAD Date#(Date, 'MMM DD, YYYY') as Date, 

     Name,

     Revision

FROM

[2015-01-31-ecoReport.xlsx]

(ooxml, embedded labels, table is RawData);

alexandros17
Partner - Champion III
Partner - Champion III

this is the correct syntax for load:

LOAD Date,
month(Date#(Date, 'MMM DD, YYYY')) as Month,
year(Date#(Date, 'MMM DD, YYYY')) as Year,
Name,
Revision
FROM
....

buzzy996
Master II
Master II

PFA,