Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - SQL Usage » Joins: Retrieving Data from Several Tables » Joins overview

Joins overview Next Page

The FROM clause


Use the FROM clause to specify which base tables, temporary tables, views or derived tables to join. The FROM clause can be used in SELECT or UPDATE statements. An abbreviated syntax for the FROM clause is as follows:

FROM table-expression, ...

where:

table-expression:
table | view | derived table | joined table | ( table-expression, ... )

table or view:
[userid.] table-or-view-name [ [ AS ] correlation-name ]

derived table:
( select-statement ) [ AS ] correlation-name [ ( column-name, ... ) ]

joined table:
table-expression join-operator table-expression [ ON join-condition ]

join-operator:
[ KEY | NATURAL ] [ join-type ] JOIN | CROSS JOIN

join-type:
INNER | FULL [ OUTER ] | LEFT [ OUTER ] | RIGHT [ OUTER ]

Notes

You cannot use an ON clause with CROSS JOIN.

For the complete syntax, see FROM clause.

For the syntax of the ON clause, see Search conditions.