Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

loading columns into rows from excel

Hi

i have a table as below i want columns as rows

   A                   B                   D                  E

employeeaaaastatusyes
salary1000locationindia
age21typeneutral
roleGM


my output should be as below

employee      salary      age       role     status   location   type

aaa               1000         21        gm      yes      india       neutral

1 Solution

Accepted Solutions
sunny_talwar

Not the best ways to do this, by may be this:

Table:

LOAD RowNo() as Key,

  employee,

     salary,

     age,

     role

FROM

b.xlsx

(ooxml, embedded labels, table is Sheet1, filters(

Transpose(),

Remove(Row, Pos(Top, 5)),

Remove(Row, Pos(Top, 4)),

Remove(Row, Pos(Top, 3))

));

Left Join (Table)

LOAD RowNo() as Key,

  status,

     location,

     type

FROM

b.xlsx

(ooxml, embedded labels, table is Sheet1, filters(

Transpose(),

Remove(Row, Pos(Top, 3)),

Remove(Row, Pos(Top, 2)),

Remove(Row, Pos(Top, 1))

));


Capture.PNG

View solution in original post

5 Replies
sunny_talwar

Not the best ways to do this, by may be this:

Table:

LOAD RowNo() as Key,

  employee,

     salary,

     age,

     role

FROM

b.xlsx

(ooxml, embedded labels, table is Sheet1, filters(

Transpose(),

Remove(Row, Pos(Top, 5)),

Remove(Row, Pos(Top, 4)),

Remove(Row, Pos(Top, 3))

));

Left Join (Table)

LOAD RowNo() as Key,

  status,

     location,

     type

FROM

b.xlsx

(ooxml, embedded labels, table is Sheet1, filters(

Transpose(),

Remove(Row, Pos(Top, 3)),

Remove(Row, Pos(Top, 2)),

Remove(Row, Pos(Top, 1))

));


Capture.PNG

iahamedabdullah
Partner - Contributor II
Partner - Contributor II

Do this steps:

Load script --> table Files(Select your Excel file) --> Next --> Enable Transformation Step --> Rotate tab --> Transpose

You will get load script Similar to this:

LOAD employee,

     salary,

     age

FROM

(ooxml, embedded labels, table is Sheet1, filters(

Transpose()

));

Not applicable
Author

Capture.PNG

hi from the above code i'm getting the above error

sunny_talwar

Are you using the Excel file you attached? Have you also checked the path to make sure that path is correct?

Not applicable
Author

greate super working fine can you elaborate me the logic