Split data table

Hi, here I have a data table scraped from wed, which contain few identical rows, and i need to split the data table based on key word in row index 0 …

Fy kind info: i have tried, to keep and skip query, that is not matching the requirement…

Please let me know is there any other way to split the dt??

@thevaraju4596

Welcome to our uipath community.

Could you please tell more details for better understanding. It would be great if you share some sample input and output. So that we can check and help you.

Hi lakshman

Please find the below sample dt.
were i need to split the data table into 3 data table ref coverage0 , and coverage 1 in 0th row index.

row 0 row1
coverage0 yes
health plan xxx
policy yyy
type hhh
coverage 1 no
coverage 1 yes
health plan xxx
policy yyy
type hhh

Hey @thevaraju4596 :wave:

Could you be a bit more specific? You want the rows with coverage 0 and coverage 1 to be in the same DT and move the rest to a new one?

Hi @monsieurrahul

I just need to split a dt into 3 different data tables, were my delimeters are coverage 0 and coverage 1…

Thanks in advance…

There are multiple ways to achieve this:

  1. Filter the DT and use it as required. For this, you can go with Filter Data Table activity or use Select method.

  2. Use 3 Build Data Table activities, iterate through the current table (the one you have posted) and use an if condition to add the item arrays to the respective build DTs.

Try it and let me know if you are facing any issues!

Cheers!

1 Like

Just confirming, you have marked the columns as rows. Is this a datatable with two columns? What should the output look like? 3 datatables? Please give an example of the output.

Hi @Matt_S

Apologise, yeah I have marked column as rows
And output dt in format.
Dt1

coverage0 yes
health plan xxx
policy yyy
type hhh

Dt2
coverage 1 no
Dt3

coverage 1 yes
health plan xxx
policy yyy
type hhh

Seems like monsieurrahul post should work.

1 Like