Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
sourabhverma107
Partner - Contributor III
Partner - Contributor III

Custom Delimiter "«" and add Header, Footer.

Hi All,

we have a requirement to generate the file through Qlikview. I have one table which needs to be stored in .txt format with delimiter '«' which is character chr(171).

Then we need to add above line which is a header and last line which is a footer mentioned in the below image.

So could you please help on this, as delimiter is not supported by Qlikview, also I dint find a way to store header and footer for the same.

d6ff41f3-afad-407c-93db-4b057a773595.jpg

Thanks,
Sourabh

 

@stevedark 

1 Solution

Accepted Solutions
stevedark
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi @sourabhverma107 

The STORE table does have the option to specify a delimiter, it would be something like:

STORE Data INTO [lib://MyLib/MyFile.txt] (txt, delimiter is chr(171));

What you would not be able to do in that way though is add a different header and footer row to the text file.

If you take a look at this blog post, it has example code for constructing an HTML table in the Qlik load script. In this case each line of the table is written into a single string and then added to the table. This is then written out with header and footer code in there also.

https://www.quickintelligence.co.uk/write-csv-qlikview-store/

This should get you most of the way to where you need to be. You may hit snags with file encoding (you may need to specify UTF8, for example), but hopefully you will be able to work around those.

Good luck!

Steve

View solution in original post

2 Replies
stevedark
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi @sourabhverma107 

The STORE table does have the option to specify a delimiter, it would be something like:

STORE Data INTO [lib://MyLib/MyFile.txt] (txt, delimiter is chr(171));

What you would not be able to do in that way though is add a different header and footer row to the text file.

If you take a look at this blog post, it has example code for constructing an HTML table in the Qlik load script. In this case each line of the table is written into a single string and then added to the table. This is then written out with header and footer code in there also.

https://www.quickintelligence.co.uk/write-csv-qlikview-store/

This should get you most of the way to where you need to be. You may hit snags with file encoding (you may need to specify UTF8, for example), but hopefully you will be able to work around those.

Good luck!

Steve

sourabhverma107
Partner - Contributor III
Partner - Contributor III
Author

Hi Steve,

 

Thank you for the prompt response.

Sure i will follow the post and try to do the same.

Thanks,
Sourabh