Sometimes you want to create a new table that contains
both columns and rows that are derived from an existing table or set
of tables. In this situation, you can submit one PROC SQL step that
does both of the following:
populates the table with data from
the result of a PROC SQL query.
To create a table from a query result, use a CREATE
TABLE statement that includes the keyword AS and the clauses that
are used in a query: SELECT, FROM, and any optional clauses, such
as ORDER BY.
General form, CREATE
TABLE statement with query clauses:
CREATE TABLE table-name AS
... table-n | view-n>
<optional query ...