Extract Data Table and output 1 Row many Columns, instead of 1 Column many rows

Hi Guys, Ill try my best to explain this very simple problem.

Using Extract Data Table the output gives ONE COLUMN, with many rows.

How do I edit the xml editor to out put the data as ONE ROW, with many columns

eg
This :

Which produces:
Column1
Row1
Row2
Row3
Row4
etc

I would like to extract, so the data output is

ROW ONE: Column1:Column2:Column3:Column4:etc

This would really help so that when I do For Each row, it iterates through the scraped data as a row.

POSTED 16th November 2022.

**Please do not respond with… “try THIS”, without describing what “THIS” is .tx

HI,

We can achieve this using AddDataColumn in ForEachRow loop.
First, create DataTable for storing result. Next add a DataRow to store result data.
Then, In ForEachRow loop for source DataTable, add DataColumn to result DataTable by each row and set data to added column.

Sample20221117-1.zip (3.0 KB)

OR there are some activities packages which have DataTable Transpose function in MarketPlace. If you can use Custom activity in it, it might help you.

Hope this helps you.

Regards,

Thanks for that Yoichi,

I downloaded your example and it works perfect.

However, I have a Data Table already. Its an Extract Data Table. The results are stored in variable ExtractdataTabel.

The data table has ONE Column, and multiple rows. The Rows can be anything from 1 row, to 50 rows max. The row will vary depending on the Extract.
How would incorporate your solution with a pre-existing DAtatable using the Tabel Extraction Activity

If I use you example, would I have to Build a data table with 50 Rows. I understand it would ignore the nulls.

In your example though, the {} in the add data column, does not seem to function. It returns a n error that the array is larger than the rows in the table. OF course, is does not say which rows or which tables.

Im trying to active ONE ROW, and in this case, 23 columns

Instead of : Table Extract producing, ONE COLUMN, 23 rows.

What about editing the the Extract Meta Data?

Something like this

Hi,

It’s mostly same. Can you check the following sample? This converts from ExtractDataTable which has single column.

Sample20221117-1v2.zip (4.2 KB)

Regards,