Which three statements are true about the Oracle join and ANSI join syntax?
The answers the exam expects are:
3) The Oracle join syntax supports creation of a Cartesian product of two tables.
4) The SQL:1999 compliant ANSI join syntax supports natural joins.
7) The SQL:1999 compliant ANSI join syntax supports creation of a Cartesian product of two tables.
3) is interesting, because Oracle (AKA SQL:89 compliant ANSI) join syntax doesn’t have an explicit notation for CROSS joining: we just omit the relevant criteria in the WHERE clause. This makes it too easy to accidentally create Cartesian products, and is one of the arguments in favour of using SQL:99.
This option highlights the problem with such exam questions:
- The Oracle join syntax performs better than the SQL:1999 compliant ANSI join syntax.
Whilst this is generally not true and performance is equivalent, there are edge cases where it is true, mainly related to outer joins. The more recent our version of Oracle the fewer and more edgy those cases become. It’s not an argument for using the older syntax, just something to bear in mind. Find out more.