Date: Sat, 24 Sep 2011 19:08:20 -0400
Reply-To: bbser 2009 <bbser2009@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: bbser 2009 <bbser2009@GMAIL.COM>
Subject: Re: how to change existing integrity constraints
Content-Type: text/plain; charset="us-ascii"
Thank you very much.
I was focusing on the how to change question, forgot the real rule behind.
Best regards, Max
From: DUELL, BOB [mailto:firstname.lastname@example.org]
Sent: September-24-11 6:16 PM
To: bbser 2009; SAS-L@LISTSERV.UGA.EDU
Subject: RE: how to change existing integrity constraints
Sorry, but SAS does not support "cascade" for "delete"; only for "update".
See the SQL Procedure User's Guide, ALTER TABLE statement.
The description of "referential-action" appears below the description of the
MODIFY clause rather than more naturally after the description of
"constraint". The terms seem to be sorted alphabetically rather than in
context. Not the clearest of SAS documentation. See also the chapter
"Understanding Integrity Constraints" in the "SAS Language: Concept" book
(SAS Files Concepts -> SAS Data Files).
Good question though; I haven't messed with SAS integrity constraints in a
very long time so this was another blast from the past for me.
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of bbser
Sent: Saturday, September 24, 2011 2:29 PM
Subject: how to change existing integrity constraints
I was wondering if anyone knew how to change an existing integrity
For example, consider the code below.
After running it, how to change the foreign key rule "on delete restrict" to
be "on delete cascade"?
Any comments or suggestions are appreciated!
create table employees
ID num primary key,
create table salaries
ID num references employees on delete restrict
on update set null,