Adding a Dynamic Data row into datatable

Hi,

I was facing a challenge where I have a collection of data [extracted from .txt file] need to add into a data table. The data row I have to start from column number 35 to n (n = 173 max. rows of data). I have used add data row activity for first 35 rows since they are static value but from there it could be a collection of data i was supposed add from 35th row in the same Datatable.

I was using excel activities but it consuming more time(it taking 5 min to extract for 1 case, i have 7000+ ), so I cant use Excel activity.

Kindly suggests any solution for this. Thanks in advance!!

Hi @Alfa_Alfa08

create datatable with build data table activity then use add data row inside a loop to add static and dynamic values for better performance use write csv or write text file instead of excel this approach is aligned with UiPath best practices for handling large data without excel dependency.

If you found helpful please mark as a solution. Thanks
Happy Automation with UiPath

Hi,

Can you share your input file and expected output as file? It’s no problem if dummy data.

I think GenerateDataTable activity may help you.

Regards,

@prashant1603765 Thanks for your response!

Yeah I have created Generate DT and added static values until row 35. From there I have a for each data for next rows

The Plan coverage is data where I am using for each to extract each coverage payer because, i can get max. 173 coverage plans for a case. So I have to incorporate into Same Datatable after URL (35th row in my Datatable)

Payer Information
Phone Number: 1234354677
URL: uipath.com

@Yoichi Kindly help

Hi,

Can you share the above as text file because some characters are identified as special character in the forum and it’s not same as original text.
Also can you share expected output as xlsx file etc?

Regards,

Sure. Please find below
test2.txt (3.2 KB)

@Yoichi Sorry, I haven’t noticed excel format. Please find below.
test2.xlsx (9.6 KB)

Hi,

Thank you for sharing. Can you share additional information for rule to map into datatable?
For example, HBPA Coverage Message1.5 (where Alfa; Alfa; Alfa comes from?)

Regards,

@Yoichi Sorry for delayed response.
Yes I was merging all message items into a single column

Item 2 item 3 item 4 are having different data. For example:

Plan Coverage
(Family)
Out of Network
Deductible: $20
MSG: DEDUCTIBLE IS MET; AMOUNT IS SATISFIED
MSG: SPECIALIST

Hello @Yoichi any ideas, Please share.

HI,

The above test2.xlsx is result of test2.txt?
If not, can you share result of test2.txt, as xlsx file?

Regards,

Yes Its result from test2.txt

Thanks,
A

Hi,

It seems your requirement is a little complicated.
The following will return your expected result from the text (except column name). Can you check this?

Sample
Sample20250527-1.zip (4.7 KB)

Regards,

Thank you @Yoichi for the solution. unfortunately, the solution is not providing expected results.

Could Please help me with a query,

  1. Please check test2.xlsx sheet1, sheet 2 are datatables [for each case i am taking Datatables as fresh]
  2. Can I get output merging the data in new DT and Later I can append in final data excel sheet.

Final Data.xlsx (11.2 KB)
test2.xlsx (9.5 KB)

Thanks,
A