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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
QlickySense
Creator
Creator

SET csv file as variable

Hello 

 

SET DataTABLE = [Data.xlsx] (ooxml, embedded labels, table is [Data]);

It let me have DataTable with the path to the Data.xlsx file, then when I load some field I just use From $(DataTABLE);

I would like to SET csv file this way, but it doesnt work for me, I got errors

SET DataTABLE = [Data.csv] (txt, codepage is 28591, embedded labels, delimiter is ' , ', msq);

Any ideas?

Labels (3)
2 Replies
Or
MVP
MVP

Your issue is probably the quotes in the [delimiter is ','] section. Have a look at https://qlikviewcookbook.com/2018/01/let-set-quotes/

 

Saravanan_Desingh
MVP
MVP

Try something like this,

SET DataTABLE = '[Data.csv] (txt, codepage is 28591, embedded labels, delimiter is '&Chr(39)&','&Chr(39)&', msq)';

Use it like this,

LOAD *
FROM $(DataTABLE)
;