Joining of tables is required when the dataset query design demands for more than one table. The following sections describes the steps required to create and edit the relationships between tables.
Refer Create Data section for better understanding with the following steps.
Click on the Join
icon in the query designer toolbar to open Query Joiner
dialog.
The Join
icon in the query designer toolbar will be in disabled state, if there is only one table found dropped in table design view like below:
The Join
icon will get enabled once the second table found dropped in table design like below:
Drag and Drop tables here
like below.
Left Table - The Left Table
drop-down list illustrates the list of table dropped in design area.
Right Table - The Right Table
drop-down list illustrates the list of table dropped in design area. By default, the table which you have dropped recently will be selected in this field.
In the below snap, the new relationship is initiated between SalesOrderHeader
and SalesOrderDetail
tables.
The joins are used to retrieve data from two or more data tables, based on a join condition.
Types:
Refer Supported join types section to learn about the purpose of each join type.
In the below snap, inner join
is created between the SalesOrderHeader
and SalesOrderDetail
tables.
Left field - The available columns of the table selected in the Left Table drop-down list will be listed here.
Right field - The available columns of the table selected in the Right Table drop-down list will be listed here.
In the below snap, the join field is created for SalesOrderID
column in both tables.
To compare the values of the two columns (one from each table) between tables, any of the operator list shown in the below image can be used.
In the below snap, the Equal
operator is applied between SalesOrderID
column of both tables.
If you want to create multiple join condition for single table relation follow the below steps:
Add Field
button to create multiple join conditions for single table relation.
OK
button.
Join
icon in the toolbar to open the Query Joiner
dialog.
Edit
icon in the respective field.
tick
icon to update the edited join condition.Ok
button to save the modified join relationship.To delete a join condition in a table relation follow the below steps.
Query Joiner
dialog.tick
icon to update the join condition and then click on the Ok
button to save the table relation.A table relation must have atleast one join condition.
Query Joiner
dialog.Ok
button to save the joiner state.Query Joiner
dialog and click on the ADD
icon to create a new table relation.
OK
button to save the joiner state.