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

linking custom text with dates

Hi,

i have a table that contains month generated in the foll. format:

Date(monthStart(addmonths(today(),-2)), 'MMM-YY'); viz. Jan-12 Dec-11 etc.

Thus the table structure is something like

COL1, COL2, COL3, MonthYear

I want to join an inline table with the above based on MonthYear

however, it doesn't happen

LoadText:

LOAD * INLINE [  

MonthYear, LoadDate

DEC-11, 09-DEC-2011

JAN-12, 11-JAN-2012

];

Can anybody please suggest what am i missing in the above inline table.

Note: i have tried all combinations of monthyear like DEC-11, dec-11, Dec-11 but the inline table just doesn't join...

1 Solution

Accepted Solutions
swuehl
MVP
MVP

The MonthYear you created in the first table is actually a dual with text as well as numeric representation.

Try creating your inline table value in the same way like:

Set DateFormat = 'DD-MMM-YYY';

LoadText:

LOAD

LoadDate,

Date(monthstart(LoadDate),'MMM-YY') as MonthYear

INLINE [ 

LoadDate

09-DEC-2011

11-JAN-2012

];

View solution in original post

2 Replies
swuehl
MVP
MVP

The MonthYear you created in the first table is actually a dual with text as well as numeric representation.

Try creating your inline table value in the same way like:

Set DateFormat = 'DD-MMM-YYY';

LoadText:

LOAD

LoadDate,

Date(monthstart(LoadDate),'MMM-YY') as MonthYear

INLINE [ 

LoadDate

09-DEC-2011

11-JAN-2012

];

Not applicable
Author

thank you, it worked