# Datatable, Enumerable error

**URL:** <https://forum.uipath.com/t/datatable-enumerable-error/2862365>\
**Category:** Activities\
**Tags:** question, system, activities\
**Created:** [June 23, 2025, 2:07pm UTC](https://forum.uipath.com/t/datatable-enumerable-error/2862365 "2025-06-23T14:07:43Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Parth\_Sharma](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/parth_sharma/32/512798_2.png) [@Parth\_Sharma](https://forum.uipath.com/u/Parth_Sharma)\
**Post date:** [June 23, 2025, 2:07pm UTC](https://forum.uipath.com/t/datatable-enumerable-error/2862365/1 "2025-06-23T14:07:43Z")

</div>

Hello forum,

Problem:  
I am a beginner in UiPath and I want to join 2 datatables as shown in screenshot based on 2 matching columns, and then pick the columns that I need from table1 and table2 and save it to a IEnumerable variable matchedRows.  
I then want to append the result(matchedRows) to an existing table 3 which has the same columns as table 1.

My approach:  
I tried converting tables to Enumerables and then use join to accomplish this but I am getting errors like :  
the type ‘ixmlserializable’ is defined in an assembly that is not referenced

What would be the best way to update datatable3 with new rows based on above criteria? Any alternatives or fixes to my current approach?

 ![image](https://global.discourse-cdn.com/uipath/original/4X/1/3/c/13c9eef72e37900a4eddde1f4de6ae287d7f26c8.png)

Please feel free to change the subject line as I wasn’t sure what would be the best way to describe this post!

---

<div class="post-metadata">

**Author:** ![prashant1603765](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/prashant1603765/32/523412_2.png) [@prashant1603765](https://forum.uipath.com/u/prashant1603765)\
**Post date:** [June 23, 2025, 2:25pm UTC](https://forum.uipath.com/t/datatable-enumerable-error/2862365/2 "2025-06-23T14:25:48Z")

</div>

Hi @Parth_Sharma

Pls check this,

> [@Join Datatable Using Linq](https://forum.uipath.com/t/join-datatable-using-linq/773434):
>
> Hi Team, I have 2 DT as shown in below image, I want to join both as DT3 Using Linq, Anyone Kindly Suggest [image] [{D1E93AFD-7059-45B8-80E5-FD02152F87CB}] [{C5A4ADCC-6197-44EA-AF91-A882F6851F4F}]

OR

> [@How to join two data table based on particular column](https://forum.uipath.com/t/how-to-join-two-data-table-based-on-particular-column/485219/4):
>
> Hi @Raja.G How about this expression? (From data1 In Dt1.AsEnumerable() Join data2 In Dt2.AsEnumerable() On data1("XX no") Equals data2("XX no") Select DtClone.Rows.Add({ data2("XX no"),data1("Name"),data2("Status"),data2("Comment"),data2("Date")})).copytodatatable Check out the XAML file [TwoDTJoinDataTable.xaml](https://forum.uipath.com/uploads/short-url/ktPspsaK5OUo8znSEIK32hsXPiL.xaml) (12.4 KB) Output [image] Hope it will helps Regards Gokul

Happy Automation

---

<div class="post-metadata">

**Author:** ![Aleem\_Khan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/aleem_khan/32/534869_2.png) [@Aleem\_Khan](https://forum.uipath.com/u/Aleem_Khan)\
**Post date:** [June 23, 2025, 6:27pm UTC](https://forum.uipath.com/t/datatable-enumerable-error/2862365/3 "2025-06-23T18:27:48Z")

</div>

(From data1 In Dt1.AsEnumerable()  
Join data2 In Dt2.AsEnumerable()  
On data1(“XX no”) Equals data2(“XX no”)  
Select DtClone.Rows.Add({  
data2(“XX no”),data1(“Name”),data2(“Status”),data2(“Comment”),data2(“Date”)})).copytodatatable()

---

<div class="post-metadata">

**Author:** ![Anil\_G](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/anil_g/32/524291_2.png) [@Anil\_G](https://forum.uipath.com/u/Anil_G)\
**Post date:** [June 23, 2025, 6:43pm UTC](https://forum.uipath.com/t/datatable-enumerable-error/2862365/4 "2025-06-23T18:43:01Z")

</div>

@Parth_Sharma

Easier way would be to use a join datatable activity first and then a filter datatable activity to get only columns you need from the joined table

Then use merge datatable to merge the joined data to table3 as needed..one thing you need to remember is after getting only columns you need the column names should match with table 3 to merge properly else you can rename the columns as you need and then merge

So 3 steps

1. Join dattable activity table 1 and 2
2. Filter datatable for joined table and get only columns you need
3. Merge datatable for appending joined datatable to table3

Cheers

---

<div class="post-metadata">

**Author:** ![Maggi\_Singaravelan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/maggi_singaravelan/32/512700_2.png) [@Maggi\_Singaravelan](https://forum.uipath.com/u/Maggi_Singaravelan)\
**Post date:** [June 23, 2025, 6:43pm UTC](https://forum.uipath.com/t/datatable-enumerable-error/2862365/5 "2025-06-23T18:43:02Z")

</div>

Is there a particular reason you want to keep the data as IEnumerable?

If you can use the data as a datatable itself, You can use “Join DataTable” activity to join table 1 and table 2, then use “Filter DataTable” activity to keep only particular columns.

Finally use “Merge Datatable” activity to add the result to table 3 or even “for each row” loop and the use “Add data row” activity to add the new rows.
