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

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
upaliwije
Creator II
Creator II

SYNTAX ERROR

Please correct following syntax in load script

IF(DUAL(YEAR(INT_DATE)<2015,'OTHER_YEARS',Month(INT_DATE) &'-'& YEAR(INT_DATE)),INT_DATE)As Month_Year,

Labels (1)
1 Solution

Accepted Solutions
jagan
Partner - Champion III
Partner - Champion III

Hi,

I think it should be

DUAL(IF(YEAR(INT_DATE)<2015,'OTHER_YEARS',Month(INT_DATE) &'-'& YEAR(INT_DATE)),MonthEnd(INT_DATE))As Month_Year,


Hope this helps you.


Regards,

jagan.

View solution in original post

5 Replies
sunny_talwar

May be this:

Dual(If(Year(INT_DATE) < 2015, 'OTHER_YEARS', Month(INT_DATE) &'-'& Year(INT_DATE)), INT_DATE) as Month_Year,

sunny_talwar

Not sure if this is how you want it to be, but you can also try something like this:

Dual(If(Year(INT_DATE) < 2015, 'OTHER_YEARS', MonthName(INT_DATE)), INT_DATE) as Month_Year,

Best,

Sunny

Anonymous
Not applicable

If I got the requirement right:

if(YEAR(INT_DATE)<2015, dual('OTHER_YEARS',0), Date(INT_DATE,'MMM-YYYY')) As Month_Year

The 0 here is for sorting, so the "other years" is on top.  Date() is dual by nature.

jagan
Partner - Champion III
Partner - Champion III

Hi,

I think it should be

DUAL(IF(YEAR(INT_DATE)<2015,'OTHER_YEARS',Month(INT_DATE) &'-'& YEAR(INT_DATE)),MonthEnd(INT_DATE))As Month_Year,


Hope this helps you.


Regards,

jagan.

upaliwije
Creator II
Creator II
Author

Thank you all