Joining tables

Use the Join page of the SQLAssist SmartGuide to join tables in an SQL statement. The join page displays the columns of each table selected in the Tables page.


Join page of SQLAssist SmartGuide

Requesting a join

  1. Select one of the displayed columns in a table. The informational area indicates the status of the join.
  2. Select a displayed column in another table. A line appears connecting the columns to indicate the requested join. Notice that the information area is updated. The information area also indicates if a requested join is invalid (for instance, because of a mismatch in the data type of the columns). The control buttons on the join page are also enabled.


    Joined tables

    By default, a join request is assumed to be an inner join. An inner join requests only the rows where the values of the two columns match. You can also request other types of joins by selecting Options. You can select:

    Inner join is also an option. You can choose this if want to change a join type from a left or right outer join.

  3. Select Join. The color of the join line changes to red indicating that the join is enabled.

Requesting additional joins

You can request additional joins in the same way as the initial join. You can join other displayed columns in the same tables or in other tables. If you request multiple joins, you can navigate between the joins by selecting > or <. The selected join is indicated by a red join line.

Removing a join

To remove a join, select the joined columns or navigate to the pertinent join. Then select Unjoin. The join line is removed.

When you finish the join

When you finish the join specification, select Next. This displays the Condition 1 page of the SQLAssist SmartGuide. Use this page to specify a search condition for the SQL statement.

When you complete the specification of your SQL statement, select Finish. This generates the code for the SQL statement and closes the SQLAssist SmartGuide.

To cancel the visual composition of the SQL statement, select Cancel.


Specifying the tables for an SQL statement
Specifying search conditions
Specifying result columns
Sorting the result set
Remapping data to a different SQL data type
Displaying the SQL statement