Juction tables

  • Thread starter Thread starter Bob Day
  • Start date Start date
B

Bob Day

Using VS 2003, VB.net, SQL MSDE

Doing my first junction table in Server Explorer, Database diagrams, and
having the following error message below on one of the relations. I am
following the instructions exactly, so I am not sure what the problem is.

3 tables in a telephony application:
Table 1 is Calls (i.e. telephone calls)
Table 2 is Calls_Customer_Junction (consists of only primary keys from table
1 and 2, which are both primary keys in table 2)
Table 3 is Customers (i.e. Customer who answered the call)

The relationship between table 1 and 3 is many to many (I think), each Calls
row could have a different Customers row and each Customers row could be
from a different Calls row.

The one to many relation from Table 1 to Table 2 draws fine and saves fine.
But, the one to many relation from Table 3 to Table 2 draws fine, but when
you save it, you get the error message below.

Not sure what the problem is. Any ideas? Any links that might help?

Thanks.
Bob

'Customers' table saved successfully
'Calls_Customers_Junction' table
- Unable to create relationship 'FK_Calls_Customers_Junction_Customers'.
ADO error: Introducing FOREIGN KEY constraint
'FK_Calls_Customers_Junction_Customers' on table 'Calls_Customers_Junction'
may cause cycles or multiple cascade paths. Specify ON DELETE NO ACTION or
ON UPDATE NO ACTION, or modify other FOREIGN KEY constraints.
Could not create constraint. See previous errors.
 
can you post a structure, so group can realize the how you want to make
relations with tables?

Rajesh Patel
 
The foreign key must be the same data type as the primary key.

If you would like to show the detail structure of the three tables, we are
glad to help you check this problem.

Sincerely,

Kevin
Microsoft Support

This posting is provided "AS IS" with no warranties, and confers no rights.
Get Secure! - www.microsoft.com/security

--------------------
| From: "Bob Day" <[email protected]>
| Subject: Juction tables
| Date: Wed, 8 Oct 2003 12:37:45 -0500
| Lines: 35
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.adonet
| NNTP-Posting-Host: dhcp065-029-072-239.indy.rr.com 65.29.72.239
| Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP09.phx.gbl
| Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.adonet:63295
| X-Tomcat-NG: microsoft.public.dotnet.framework.adonet
|
| Using VS 2003, VB.net, SQL MSDE
|
| Doing my first junction table in Server Explorer, Database diagrams, and
| having the following error message below on one of the relations. I am
| following the instructions exactly, so I am not sure what the problem is.
|
| 3 tables in a telephony application:
| Table 1 is Calls (i.e. telephone calls)
| Table 2 is Calls_Customer_Junction (consists of only primary keys from
table
| 1 and 2, which are both primary keys in table 2)
| Table 3 is Customers (i.e. Customer who answered the call)
|
| The relationship between table 1 and 3 is many to many (I think), each
Calls
| row could have a different Customers row and each Customers row could be
| from a different Calls row.
|
| The one to many relation from Table 1 to Table 2 draws fine and saves
fine.
| But, the one to many relation from Table 3 to Table 2 draws fine, but when
| you save it, you get the error message below.
|
| Not sure what the problem is. Any ideas? Any links that might help?
|
| Thanks.
| Bob
|
| 'Customers' table saved successfully
| 'Calls_Customers_Junction' table
| - Unable to create relationship 'FK_Calls_Customers_Junction_Customers'.
| ADO error: Introducing FOREIGN KEY constraint
| 'FK_Calls_Customers_Junction_Customers' on table
'Calls_Customers_Junction'
| may cause cycles or multiple cascade paths. Specify ON DELETE NO ACTION or
| ON UPDATE NO ACTION, or modify other FOREIGN KEY constraints.
| Could not create constraint. See previous errors.
|
|
|
 
Back
Top