Activities
latest
false
Banner background image
Workflow Activities
Last updated Apr 22, 2024

JoinDataTables

Combines rows from two tables by using values common to each other, according to a Join rule, which is specified in the Join Type parameter.

Definition

Namespace: UiPath.Activities.System.API

Assembly: UiPath.System.Activities.Api (in UiPath.System.Activities.Api.dll)

JoinDataTables(DataTable, DataTable, List<JoinOperationArgument>, JoinType)

DataTable JoinDataTables(
	DataTable dataTable1,
	DataTable dataTable2,
	List<JoinOperationArgument> arguments,
	JoinType joinType
)DataTable JoinDataTables(
	DataTable dataTable1,
	DataTable dataTable2,
	List<JoinOperationArgument> arguments,
	JoinType joinType
)
dataTable1 DataTable
The first table that you want to use in the Join operation, stored in a DataTable variable.
dataTable2 DataTable
The second table that you want to use in the Join operation, stored in a DataTable variable.
Note: The order in which the two tables are supplied is very important, because it influences the structure of the resulting table, according to the option selected in the JoinType property field.
arguments List <JoinOperationArgument>
The conditions to join the data tables by.
Note: If a column from DataTable2 shares the same name with a column from DataTable1, then the name of the column from DataTable2 is changed to [ColumnName]_1 in the resulting table. If a column with the [ColumnName]_1 name already exists, the consecutive number that is not already in use is used instead. For example, if DataTable1 has columns named ID, ID_1 and ID_2, and DataTable2 has a column named ID, after the join, the column in DataTable2 is named ID_3.
joinType JoinType
The type of Join operation you want to use. The following options are available:
  • Inner - Keep all rows from DataTable1 and DataTable2 which meet the Join rule. Any rows that do not meet the rule are removed from the resulting table.
  • Left - Keep all rows from DataTable1 and only the values from DataTable2 which meet the Join rule. Null values are inserted into the column for the rows from DataTable1 that don't have a match in the DataTable2 rows.
  • Full - Keep all rows from DataTable1 and DataTable2, regardless of whether the join condition is met. Null values are added into the rows from both tables that don't have a match.

Return value

Output DataTable.

Was this page helpful?

Get The Help You Need
Learning RPA - Automation Courses
UiPath Community Forum
Uipath Logo White
Trust and Security
© 2005-2024 UiPath. All rights reserved.