Beginning in SAS9 of PROC SQL, a warning is written to the SAS log when creating a table with the same name as any table listed on the FROM clause.
The '92 ANSI standards for SQL state that recursive table references are illegal unless the SQL conforms to the "FULL SQL" ANSI standard or the implementation chooses to allow recursive references to be used. PROC SQL does not follow the "FULL SQL" ANSI standard. Recursive references, used in update operations, can return incorrect results.
It is for these reasons that recursive references are not supported.
The "recursive reference" warning can be prevented for the CREATE TABLE statement in SAS 9 by including the UNDO_POLICY=NONE option on the PROC SQL statement. The use of the UNDO_POLICY=NONE option will only prevent the warning for SQL queries similar to the following:
proc sql undo_policy=none; create table one as select * from one; quit;
Note: The use of the UNDO_POLICY=NONE option only prevents the warning. It does not remove the inherent risk possible if recursive table references are chosen to be used.
The UNDO_POLICY=NONE option will not prevent warnings if recursive references are being made in UPDATE / INSERT / DELETE operations. Similar to:
proc sql undo_policy=none; delete from one where id in (select id from one); quit;