Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

add a column equal to variable?

Hi - is it possible to add a column to my script load equal to a variable I already set? I set vEndDate equal to the date I will be using to run the script and would like to join a Date column to the final table where Date is equal to vEndDate. I can then store the table down as part of a new QVD and know which date each set of data it is from after it concatenates. Date is not a part of any of my load files so I was hoping to create it in the script and join it to my final table. Any suggestions?

Tags (1)
2 Replies
Valued Contributor III

Re: add a column equal to variable?

you can add the values from variables into your tables

here is an example




'$(vEndDate)' as vEndDate


Re: add a column equal to variable?

Yes you can. Try this script:

LET vNow = Chr(39) & Today() & Chr(39);


LOAD Date($(vNow)) as Date

AutoGenerate 1;

Community Browser