Extract data table: Can anyone help in converting input excel(ExtractDataTableGenerated.xlsx) to expected output table(img) in form of excel?

output I want is(image):

input given (.xlsx)
ExtractDataTableGenerated.xlsx (8.0 KB)

Note: I want to convert this input excel into the table being given in image

I want the whole input excel(.xlsx) to look like the table you can see in image.
If you’ll see carefully the column headers are repeating but the data is coming correctly in respective columns and rows…except the column 3 whose values are coming last.

It will be a great help

Hi @anjasing ,

Can you please elaborate more?

Please mention which column data you want it in which column.

Thanks

hi @ermanoj3101

I want the whole input excel(.xlsx) to look like the table you can see in image.
If you’ll see carefully the column headers are repeating but the data is coming correctly in respective columns and rows…except the column 3 whose values are coming last.

if you can help.

Maybe this post can help you: Datatable column transformation - #3 by T0Bi

I’ve posted several ways on how to change datatables.

this “dataTable.Columns[“Qty”].SetOrdinal(0)” that you’ve recommended can we use for multiple columns positioning?

Yes, you can use this to put every column to whichever position you like.

Hi @anjasing ,

There is one more way to do this.

1 - Create Columns that you want in Build Data Table activity.
2 - Read the data of existing file from below query
“(From r In dtInput Select dtOutput.LoadDataRow(New Object() { r.Field(of Object)(“columnname”),r.Field(of Object)(“columnname”) },False)).CopyToDataTable”

dt Input - Input of excel file
dtOutput - Output of Build data table
Wherever i have mentioned as columnname use your column in same serial you have defined columns in build data table.

3 - Use write range activity finally for dtOutput.

Hope this will help you to achieve this task.

Thanks.

Hi, This is my .xaml followed your steps… if you can help further…not able to implement your steps fully… please help ! TableGeneration.zip (16.4 KB)

Hi @anjasing ,

The output is in “output” sheet of final excel.

You can directly use
TableGeneration.zip (19.7 KB)
Main.xaml file

@anjasing Is it working ?

If it worked please mark it as a solution for others.

Thanks

1 Like

I also want column W(of excel) values to be in column name “Successful”. If you can help further… this was a lot f help from you… thank you so much…I’ll mark it as solution afterwards… thank you very much

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.