Saturday, February 25, 2012

Multiple Cascade Paths Error

Can anyone tell me why on earth you can't have two cascade paths to a table
? This essentially means we cannot use RI and have to maintain triggers
for our DB.
I see that they haven't fixed it in 2005 either.Hi
You probably want to use a superset, but without DDL your question not
clear. http://www.aspfaq.com/etiquett_e.asp?id=5006
Also check out:
http://tinyurl.com/486q3
If this does solve your issue then it is a design problem and not a problem
with the RDBMS.
John
"Adrian Parker" wrote:

> Can anyone tell me why on earth you can't have two cascade paths to a tabl
e
> ? This essentially means we cannot use RI and have to maintain triggers
> for our DB.
> I see that they haven't fixed it in 2005 either.
>
>|||Please read the following pages.. you'll understand the problem then
first Microsofts page (I love their workaround)
http://support.microsoft.com/defaul...&NoWebContent=1
Then the WindowsITPro page that explains the problem in more detail
http://www.windowsitpro.com/Article...5520/25520.html
We migrated to SQL Server from sybase and oracle, which both handle the
scenarios correctly.
And no, I doubt we're going to rewrite a 10 year old application with 600
tables just to cope with a limitation in SQL Server,we'll have to continue
using triggers, which is really annoying.
"John Bell" <JohnBell@.discussions.microsoft.com> wrote in message
news:FD2C115B-CCD3-4864-8CDC-F6402B62A863@.microsoft.com...
> Hi
> You probably want to use a superset, but without DDL your question not
> clear. http://www.aspfaq.com/etiquett_e.asp?id=5006
> Also check out:
> http://tinyurl.com/486q3
> If this does solve your issue then it is a design problem and not a
> problem
> with the RDBMS.
> John
> "Adrian Parker" wrote:
>|||Hi
The example can be re-modelled as
Use tempdb
go
create table table1 (user_ID integer not null primary key, user_name
char(50) not null)
go
create table table2 (author_ID integer not null primary key,
author_name char(50) not null )
go
create table table3 (author_ID integer not null primary key, Action
varchar(20) not null check (Action =3D 'Created' OR Action =3D 'Last
Modified'), User_id integer not null )
alter table table3 add constraint fk_one foreign key (User_id)
references table1 (user_ID) on delete cascade on update cascade
go
Creating a view may remove the need for some of the code changes.
John
Adrian Parker wrote:
> Please read the following pages.. you'll understand the problem then
> first Microsofts page (I love their workaround)
>
http://support.microsoft.com/defaul...rt.microsoft.c=
om:80/support/kb/articles/q321/8/43.asp&NoWebContent=3D1
> Then the WindowsITPro page that explains the problem in more detail
> http://www.windowsitpro.com/Article...5520/25520.html
> We migrated to SQL Server from sybase and oracle, which both handle
the
> scenarios correctly.
> And no, I doubt we're going to rewrite a 10 year old application with
600
> tables just to cope with a limitation in SQL Server,we'll have to
continue
> using triggers, which is really annoying.
>
> "John Bell" <JohnBell@.discussions.microsoft.com> wrote in message
> news:FD2C115B-CCD3-4864-8CDC-F6402B62A863@.microsoft.com...
not
to a
triggers

No comments:

Post a Comment