Creating an Inner Join with Outer Join-Style Syntax

If you want to use a consistent syntax for all joins, you can write an inner join using the same style of syntax that is used for an outer join.
General form, SELECT statement for inner join (alternate syntax):
SELECT column-1<,...column-n>
FROM table-1 | view-1
INNER JOIN
table-2 | view-2
ON join-condition(s)
<other clauses>;
Here is an explanation of the syntax:
INNER JOIN
is a keyword.
ON
specifies join-condition(s), which are expression(s) that specify the column or columns on which the tables are to be joined.
<other clauses>
refers to optional PROC SQL clauses.
Note: An inner join that uses this syntax can be performed on only two tables or views at a time. When an inner join uses the syntax that was presented earlier, up to 256 tables or views can be combined at once. In-line views are covered later in this chapter.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.117.232.239