How to update data table like sql query?


How to combine two different data table having different column and different rows with one unique column?
I excepting like combining two tables in db and get the output like that.

Anyway do it like in uipath

1 Like

You have to use LINQ (Language Integrated Query) queries else
You have a join data table activity. Please check it.

Karthik Byggari

i would suggest to combine the datatable first and then upload to the db as that is more easier when we are performing with uipath, but we got some options below
Please find the criterias that we need to have if we want to combine two datatable with merge datatable
–both the datatable should have same number of columns
–same order of columns
–same datatype of columns
-----we lag these now
so the next way is to use, join datatable activity
–we can use FULL join condition in join datatable activity and that would combine the one column that matches and also the other columns aside in the datatable
–but still its based on the column in the datatable. Sometime it fail is alignment

–so the next way is to use typical method of joining like keeping one datatable as stable,
–adding columns with add data column activity
–using for each row loop passing the value of those columns in the second datatable to the first datatable when the condition meets between the two common columns using if condition
–this would work for sure, but takes bit more steps-robust

–and finally we can upload this to db by with uipath.database.activities and install them by going to
design tab -> manage packages -> go to official tab and search for package uipath.database.activities and install them
–where we got an activity called Insert activity where mention the table name in database and pass the datatable as input to this which will upload the combined datatable

hope this would helpyou
Cheers @ganesh_rajan

any issues to to discussed still @ganesh_rajan
hope we have accomplished