Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
If you are a Qlik Insight Bot user, join this collaborative group: JOIN GROUP
Highlighted
Not applicable

Use function in store into string

Hello,

Does anyone know if it is possible to use a function when you use store into?

Let's say I want the filename to be NameOfFile_20120216.txt

When I try the following QV complains about an "Unknown file format specifier"

store * from Table into D:\QlikViewSystems\PCD\Web\3_Load\NameOfFile_'&today()&'.txt (txt, delimiter is ';');

br

Martin

1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Use function in store into string

I wouldn't put any functions directly into the store-statement. But you can put your function into a variable

let vExportFilename = 'D:\QlikViewSystems\PCD\Web\3_Load\NameOfFile_' & today() & '.txt';

store * from Table into $(vExportFilename) (txt, delimiter is ';');

regards,

Edgar

View solution in original post

3 Replies
Highlighted
Partner
Partner

Use function in store into string

I wouldn't put any functions directly into the store-statement. But you can put your function into a variable

let vExportFilename = 'D:\QlikViewSystems\PCD\Web\3_Load\NameOfFile_' & today() & '.txt';

store * from Table into $(vExportFilename) (txt, delimiter is ';');

regards,

Edgar

View solution in original post

Highlighted
MVP & Luminary
MVP & Luminary

Use function in store into string

Hi,

Assign the file path into a variable like this

LET fileName = 'D:\QlikViewSystems\PCD\Web\3_Load\NameOfFile_'&today()&'.txt (txt, delimiter is' & char(39)& ';' & char(39) & ')';

Now assign the filename

store * from Table into $(fileName);

Hope this helps you.

Regards,

Jagan.

Highlighted
Partner
Partner

Use function in store into string

Both jagan and Edgar are correct, however you need to format the date otherwise the windows filesystem will not recognise this as a valid file name :

let vExportFilename = 'temp' & date(today(),'dd-mm-yy') & '.txt';

store temp into $(vExportFilename) (txt, delimiter is ';');

BS, Ioannis