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: 
Not applicable

Store do not write the header "no labels"

Hello
how to save csv files and do not write the header "no labels"  (the first line should contain the values, not the header)?

On utilisant Store je dois sauvegarder des fichiers CSV mais ces fichiers ne doivent pas contenir l'étiquette ou l'entête.

Malgré que j'utilise no labels ca marche pas.

comment sauvegarder des fichiers csv et ne pas écrire l’entête ( la première ligne doit contenir les valeurs et non pas l'entête)?

Voici le scénario Que j'utilise:

STORE KEY as [],

     MOIS as [] from TEST INTO TEST.csv (txt, delimiter is ';' , no labels);

;

Merci d'avance

6 Replies
Not applicable
Author

Hi there,


Stefan Stoichev has a posting about this, basically you need to replace the column headers with first row values.

https://sstoichev.eu/2015/05/02/save-qlikview-table-as-csv-without-header/

Another method

Export chart to delimited file using any delimiter and removing headers

Alternatively, you could use a powershell script or other post-processing to slice out the first row of a text file.


cheers,

Andrew

Gysbert_Wassenaar

That's not possible. The STORE command can only output tables including the field names. It cannot output files that contain only the data and not the field names.


talk is cheap, supply exceeds demand
maxgro
MVP
MVP

an idea

source:

load * inline [

field1, field2

a,1

b,2

c,3

d,4

];

tmp: NoConcatenate load * Resident source Where recno()=1;

let f1=Peek('field1', 0, 'tmp');

let f2=Peek('field2', 0, 'tmp');

final: NoConcatenate load field1 as '$(f1)', field2 as '$(f2)' Resident source where recno()>1;

store final into final.txt (txt, delimiter is ';');

1.png

Not applicable
Author

Thank you Massimo and Andrew

merci bcp

vlad_komarov
Partner - Specialist III
Partner - Specialist III

Great idea, but does not work in the case where values on the first row are identical:

source:

load * inline [

field1, field2, field3

a,1,1

b,2,2

c,3,10

d,4,4

e,4,5

f,2,6

];

tmp: NoConcatenate load * Resident source Where recno()=1;

let f1=Peek('field1', 0, 'tmp');

let f2=Peek('field2', 0, 'tmp');

let f3=Peek('field3', 0, 'tmp');

final: NoConcatenate load

field1 as '$(f1)',

field2 as '$(f2)',

field3 as '$(f3)'

Resident source where recno()>1;

store final into final.txt (txt, delimiter is ',');

Screen Shot 2017-04-18 at 4.32.10 PM.png

I am thinking about multiple joins (I have 9 fields to be saved into CSV) and I do not see another option...

Any other suggestions?

Regards,

Vlad

vlad_komarov
Partner - Specialist III
Partner - Specialist III

Found the solution:

Change the numeric format:

field1, field2, field3

a,1,1.0

VK