Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am attempting to load data from a text file where the delimiter is '|'
My load statement is
(txt, codepage is 1252, embedded labels, delimiter is '|', msq, no eof )
When the data is loaded though records are jumbled up so for instance you will see sales regions appearing under sales manager.
I have tried both standard and no quotes to no avail. Also checked specific lines using rowNo and a text editor but can't spot anything visible.
I believe this topic has been raised but no resolution was offered.
Thanks
Please post your data and script
I think I can see the issue which is basically a load of special characters in the offending records. In this case how would I isolate certain columns from being loaded in ( given this is a text file ) ?
It would help if you gave a sample of the offending lines + line before in the text file.
You can try loading few columns at a time by commenting some..
Load
TransactionDate,
CompanyName
/*,
Comments,
CustomerName,
*/
from myfile.csv
You may also want to look at purgechar function ex:purgechar(Comments,'@&,^$') as Comments
Hope this helps
Sasi
I have had this issue when some records do not have all the fields and the output is missing delimitors
I had to load the data has a big string for each record and parse the data manually within qlikview script
Hi Sid,
can you upload the txt file?
Andy
Try to remove the 'msq' from format-spec in your load statement.
Regards,
VK
Hi Vladimir
I tried that but it didnt work. Unable to upload the text file due to privacy issues unfortunately. Have tried pretty much everything including saving as an excel file / csv but to no avail.
Do you have a fixed number of columns in your text file? Is there a fixed amount of vertical bars in the file for each line? Are you sure that this is a codepage 1252 encoded file?