Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I was trying to load data from XLSB fle format, for that I had created ODBC connection as conventional file wizard wont work here.
First i created the qvds(select * from XLSB file no transformation) and then loaded the data in qvw, while reading the data from qvw i deleted some header columns from the qvd like below.
Remove(Col, Pos(Top, 1))
Remove(Col, Pos(Top, 2))
My problem is now all the column names are coming like @1 @2 @3 after loading.
Format of my XLSB is like.
Header 1 | Header 2 | Header 3 | Header 4 |
---|---|---|---|
Crap Header | |||
Crap Header | |||
Account Number | Date | State | City |
attached the sample app and qvd(note we must create the odbbc connection to read the xls)
Hi Amit,
Instead of transformation step, you can try like below,
Tab1:
LOAD F1,
F2,
F3,
F4,
[Crap Row]
FROM
TAB1.qvd
(qvd) where Len(Trim(F1))>0;
Here, F1 is a Column name. You can adapt the name as per your requirment.
Nagaraj, while generating the qvd itself i want to remove the crap rows and want data with headers(ABC,...).
Without that qvd is coming with everything and I have to delete those rows(under transformation tab) manually....and the worst part is my column names(ABC..) are not coming in QVD.
Amit,
I tried your script but I am not able to see headers rows. Strange.
yes exactly that is what happening, now if you load this qvd you wont get headers names...you will get @1 @2...
Very strange problem
Hi Amit,
With your example files:
For Excel file:
LOAD ABC,
EFG,
XYZ
FROM
[Test-1.xlsx]
(ooxml, embedded labels, header is 2 lines, table is Sheet1);
For QVD File:
LOAD F1 as ABC,
F2 as EFG,
F3 as XYZ,
FROM
[..\Downloads\TAB1.qvd]
(qvd)
WHERE Len(F1)>0
;
Regards!