Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am trying to define a variable as follows:
Let vStartDate = '01-JAN-16';
Let vLimit = 'TO_DATE('$(StartDate)', 'DD-MON-YY')';
When I am trying to load the variables I am getting the following error :
Can someone help me with the correct syntax ?
Regards,
H
did you try my prev post?
Let vStartDate = '01-JAN-16';
Set vLimit = TO_DATE('$(vStartDate)', 'DD-MON-YY');
trace $(vLimit);
SQL Select ......
From ......
Where Transaction_Date >= $(vLimit)
or with quote
'$(vLimit)'
TO_DATE is not a Qlik script function, and your statement itself does not evaluate to a valid statemten because of the quoting.
Try
Let vLimit = Date#('$(vStartDate)','DD-MMM-YY');
do you need a vLimit var for an Oracle where clause or something similar?
Let vStartDate = '01-JAN-16';
Set vLimit = TO_DATE('$(vStartDate)', 'DD-MON-YY');
Yes Maxgro.
SQL Select ......
From ......
Where Transaction_Date >= $(vLimit)
did you try my prev post?
Let vStartDate = '01-JAN-16';
Set vLimit = TO_DATE('$(vStartDate)', 'DD-MON-YY');
trace $(vLimit);
SQL Select ......
From ......
Where Transaction_Date >= $(vLimit)
or with quote
'$(vLimit)'