Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
HI
Confusing subject i know.. but let me try to explain what I need 🙂
I need to load all .csv files from a folder into a .qvd file.
That task of loading all files is simple enough, but herein lies my question.
There are about 6 different .csv files in this folder, that varies in headers, and field contents.
File example 1:
SerialNo | Created | Volume1 | Volume2 | Volume3 | Volume4 |
File example 2:
SerialNo | Created | Heat1 | Heat2 | Heat3 | Heat4 | Temperature | Delta-T | ErrorCode |
File example 3:
SerialNo | Created | Temperature1 | Temperature2 | Temperature3 | Humidity1 | Humidity2 | Humidity3 |
What I need to do is load all the files in a folder, but depending on the headers, they should be treated differently. Not only the header but the contents that comes with it in that field.
//something like this Load SerialNo, Created, If(@3='Volume1', as volume1, if(@3='Heat1', as Heat1, if(@3='Temperature' as Temperature)))
if(@4='' //and so on....
hi,
if the structure is the same between files and the fields are different, i think this solution works.
load * from lib;\\mylib\*.csv
bye
Hi
That did not do the job.
When doing so I, first of all, get a lot of syn_keys (15 in total)
Second, the data is just mixed in the fields, and not separated into the right columns.
Example 1 and Example 2 is attached.