Adding table references to SQL statements in the SQL Query Builder
In the SQL Query Builder, you can add one or more table references to an SQL statement, depending on the type of statement that you are creating.
Before you begin
Table references are objects such as tables and views that you can include in an SQL statement. You can add table references at any time while you are working on the statement.
You can create an SQL statement with multiple table references by using SELECT statements. INSERT, UPDATE, and DELETE statements operate on a single table reference.
You can add table references directly in the Tables pane, or by dragging them to the Tables pane. You can drag a table reference from a database in a database connection in the Data Source Explorer view.
- The SQL statement must be open in the SQL Query Builder.
- If you are dragging a table reference from a database, its database connection must be active.
Procedure
To add a table reference to an SQL statement in the SQL Query Builder:
Results
The table reference is added to the Tables pane and is reflected in the SQL Source pane.
If you rearrange the table graphics in the Tables pane and then save the SQL statement, the arrangement of the table graphics reverts to the linear format, and the order of the table graphics reverts to their order in the SQL statement.