Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
aheavy95
Creator
Creator

Variable not working - Unexpected token: ',', expected one of

Hi all 

I am having a problem creating a new variable in my script

aheavy95_1-1683628573925.png

 

Up until now the variable vStartLoad was based of VStartDBAdjustment_Temp and the script worked fine.

Now I was asked to change it to the date I'm getting as the 'Value' - to the start of month of that date

So I created  VStartDBAdjustment_Temp and used it in vStartLoad  and when I run the code I'm getting this error at the vStartLoad  declaration.

 

aheavy95_2-1683629308466.png

Does anyone know what am I doing wrong?

thanks

 

 

Labels (5)
1 Reply
Or
MVP
MVP

Generally speaking, I'd suggest running in debug mode and seeing what actually happens in each line and what is placed in each variable.

Specifically, you may need to place the variable in quotes in this case -

Let someVariable = chr(39) & Date('$(VStartDBAdjustment_Temp2)','YYYY-MM-DD') & chr(39);