Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    MS SQL Server


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





How To Add A Foreign Key Constraint Using The SQL Server 2000 Enterprise Manager


Hi,

How to add a foreign key constraint using the SQL server 2000
enterprise manager?
Not by SQL.

thanks




View Complete Forum Thread with Replies

Related Forum Messages:
SQL Server 2000 Diagrams Without Enterprise Manager
Hi,I currently (for a hobby project) am unable to use SQL Server 2005, and rather am stuck with 2000. Since the way diagrams are handled changed, the tool for 2005 doesn't allow for the creation of diagrams when using it for 2000 (work sweet for everything else though!).I do not have access to a developer version of SQL Server 2000's tools, and thus no Enterprise Manager, leading me to my question: Are there any free utilities to replace this functionality? I don't have MS Access or Visio or anything like that unfortunately :(

View Replies !
Sql Server 2000 Enterprise Manager Crashing
I've installed the client tools on my notebook, and EM normally works properly. However, sometimes Enterprise Manager will crash on me for no obvious reason(it generates errors, but this takes forever, so i kill it). It is not consistent, nor can I reproduce the error, but it happens about once a day, never at the same time. Anyone else see this? My pc has win2K professional on it.

View Replies !
SQL Server 2000 Enterprise Manager Error
 

Hi Guys
 
wondering if you can help me.
 
Im having an issue with SQL Server Enterprise manager. I cannot access an MSDE DESKTOP SQL Server 2000 installation that is on the same machine as enterprise manager.
 
I can access the MSDE Databae from another machine fine, but when I try to register that DB locally in Enterprise manager I get this error.
 

PC007 - Data source name not found and no default driver specified.
 
I had to install sqlserver 2000 using k=dbg and skip the MDAC install as it was giving me an install error but this shouldnt have mattered as I am running XP SP2 and it has MDAC 2.8 installed by default.
 
Any Ideas?

View Replies !
How Can I Reinstall The Enterprise Manager? (SQL SERVER 2000)
I can€™t use the DTS editor because shows an error.
So, I want to reinstall the enterprise manager without uninstall the sql server 2000, Is that possible?
If the answer is yes, How can I do that?
 
I think that reinstalling only the Enterprise Manager the DTS editor can be fixed.
 
Sql Version: Sql Server 2000
SO: Windows 2003 Server
 
Tanks in advance
Ariel.
 

View Replies !
Registering SQL Server In SQL 2000 Enterprise Manager
When Trying to register a SQL Server using Windows Authentication, I get the following error:

Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection.

When I edit the properties and make it SQL Authentication, it works fine. The SQL Server Service is starting up with a domain user account. If that makes any difference. Funny thing is, that my co-worker, can register the SQL Server in his Enterprise Manager using Windows Authentication. We are both Domain Admins and members of the servers local admin group. So, I'm not sure what to do now.
 
I checked under Security, Logins...and neither of us are listed under there.

Thanks

View Replies !
How Can I Reinstall The Enterprise Manager? (SQL SERVER 2000)
 
Something happened when the server fall down because of no disk space.
Now everything is fine but I have a problem in de DTS (from the Enterprise Manager) editor, I can€™t run, modify and even make a new DTS.
What can I do? Is it possible reinstall de DTS components without reinstall sqlserver 2000?  
 
Sql Version: sqlserver2000 Enterprise
SO Version: Windows 2003 Server
 
Thanks in advance
 
Ariel.
 

View Replies !
SQL Server 2000 Enterprise Manager Snap-in Missing
After running virus cleaning software on my HD, I suddenly find my Enterprise Manager snap-in missing and fail to initialize. Is the MMC erased or damaged? What should I do? Reinstall SQL Server 2000 or repair it? Please advise. Thanks.

View Replies !
SLOW Connection To SQL Server 2000 From Enterprise Manager
I have had a problem with Enterprise Manager connecting to SQL Server. At first this problem was experienced with one particular network user... whichever PC he logged onto, Enterprise Manager took ages to connect to SQL Server and every operation was painfully slow. Creating a new Windows NT logon fixed the problem.

I now have this same problem but only on my PC. It doesn't matter which Windows NT logon I use, using Enterprise Manager is painfully slow. I've tried creating a new Windows NT profile, checking the hard drive for errors, defragmenting the disk, reinstalling Enterprise Manager etc but nothing works.

What is strange is that connections from VB applications on my PC are fast. It is only Enterprise Manager that is slow.

I am using the latest service pack for SQL Server.

I thought it could be a problem with the Enterprise Manager registry values but don't want to start messing with them!

Has anyone else experienced this problem? Any advice would be great as I can't find any help from microsoft other than installing the latest service pack for SQL Server.

Thanks

View Replies !
MMC Error When Staring Enterprise Manager In SQL Server 2000
Hello,
Yesterday I was in SQL Server 2000 Enterprise Manager and it got hung up. I couldn't get out of it without rebooting my machine. When I tried to enter Enterprise Manager again, I got an error message "MMC Cannot Open The Selected File". So I completly shut down my machine and then started it back up, but still go the same message. I stopped the services and then rebooted again,but no luck either. Today, I still cannot open Enterprise Manager. Has anyone experienced this and worked through it? I am debating as to whether or not I should uninstall SQL Server 2000 and reinstall it? Any advice?
Thanks
Heather

View Replies !
Accessing Remote Sql Server 2000 ( Enterprise Manager Like Tool)
Hi all,I need to gain access to a remote SQL Server 2000 storing my data.The remote SQL machine can only be accessed via an internet connection,that is - it is not part of my network.I know Enterprise Manager can do the job, but EM only comes bundled inMS SQL Server, which is not installed on the client machine.Please let me know which other (preferably free) tools can performsuch remote access.Thanks,Gilad Haimov

View Replies !
Dual Instances In OnSQL Server 2000 Enterprise Manager
I am working on a site's SQL Server 2000 database on a W2k3 machine . I went into Enterprise Manager and saw that their database resides on a named instance. I did not see the default instance listed so I registered that using windows authentication. I noticed that the default instance had a user database that had the same name as the user database on the named instance that I was to work on. I looked at the properties of the databases and saw that on both the default and named instances of SQL Server that the Data Files and Log Files for the user database point to the same location.

Is this a problem? Can anyone see any issues with this? Does this mean that someone can simply connect to the named or the default instance of the SQL Server and connect to the same database?

Kirk

View Replies !
SQL Server 2000, Requesting Database Properties Lock Up Enterprise Manager
Hello,We have MS SQL Server 2000 and recently we found out that rightclicking on a database and selecting properties would lock up theenterprise manager. We have 80 Databases 4 GB Memory 2 Xeon 3.0 GHzCPUsSQL Server Runs just fine, query results are timely. It's just theproperties screen for databases that's concerning me.Any ideas why that's happening and how I could resolve it?Thanks

View Replies !
SQL Server 2000 Databases To SQL Server 2005? Enterprise Manager And Management Stuio At The Same Server?
When I proposed start to use SQL Server 2005 for new VS 2005 web sites, one of my co-workers responded that
we will update the old SQL Server 2000 databases to SQL Server 2005 when we are ready to use 2005 SQL Server.

Questions:
1. Any expected problems to upgrade old 2000 databases to new 2005 SQL Server?
2. I have installed both 2005/Management Studio Express and 2000/Enterprise Manager in my PC.  Any expected
    problems when running both 2000 and 2005 SQL Server at the same database server?
3.  What is the best configuration for running SQL Server 2005 when we have old 2000 databases?  Upgade or not upgrade?  

TIA,
Jeffrey

View Replies !
Using MS SQL Server 2005 Enterprise Manager With MS SQL Server 2000
Hi Everyone,Most of our MS SQL Servers are still running on SQL 2000, but being Iwill soon be upgrading my workstation to Vista Business I'd like toinstall MS SQL 2005 Enterprise Manager to manage them all. When Itried to install MS SQL 2000 Enterprise Manager on Vista, it gave me amessage saying it's not compatible, so I'll have to use 2005 I guess.We have LOTS of DTS scripts on our SQL 2000 server, and will 2005 EMwork with these okay? Also I want to make sure SQL 2005 EnterpriseManager won't be adding to, changing, or 'upgrading' the DTS scripts oranything on the SQL 2000 servers as we still have folks using SQL 2000Enterprise Manager.Thanks for any suggestions. I'm always leery when using cross-versionsof Microsoft applications because they are often incompatible or theydo squirly things that often break stuff.Thanks --Alex

View Replies !
What's New In Enterprise Manager 2000?
Is there anything significantly better in Enterprise Manager 2000 vs. the old EM from SQL Server 7.0?

If so I'd be willing to pay the $50 for the SQL Server 2000 Developer
Edition to get it... if not it seems dumb to pay for anything when MSDE
2000 is free and I already have the old EM.  (Although I have
installed MSDE 2000 as a new instance and can't figure out how to get
at it via EM.) 

Thanks for any insight.

View Replies !
Enterprise Manager 7.0/2000
Can the SQL 2000 Enterprise Manager be successfully installed and utilised on a pc that currently has SQL 7 and is used to administer other SQL 7 servers? Can the SQL 2000 Enterprise Manager be used to administer SQL 7?

Thanks.

View Replies !
Enterprise Manager 2000
I have just discovered something with EM 2000. In the old days (SQL Server 7), you could right click on a table, choose OPEN TABLE -> SELECT ALL ROWS and get a nice little grid with the select results. The same is true in SQL Server 2000. One thing you cannot do is update a value in that result set, which WAS something you could do in SQL Server 7. If you try it in EM 2000, you get the error message "TRANSACTION CANNOT BE STARTED WHILE IN FIREHOSE MODE". ???????
Am I just missing something, or was Microsoft so worked up about putting XML into their product, they overlooked some of the simple things that were really appreciated (and sorely missed).
If anyone can provide some insight, it would be appreciated.

Thank You

View Replies !
Having Enterprise Manager 7.0 And 2000 On Same PC
Can you have MS SQL Enterprise Manager 7.0 and 2000 on the same computer? If so, are there any special steps involved?

Thanks,

Dave

View Replies !
SQL 2000 Enterprise Manager Doesn't Run
Hello All.

I have been using my SQL 2000 Enterprise Manager for many months but it suddenly stopped working. I have uninstalled and reinstalled the software 3 times and it is still not working. When I double click on Enterprise Manager, it doesn't run. Query Analyzer works fine.

I am on Windows XP. No change in system configuration recently or any s/w upgrade, etc.

Any advise?

Thank you.

Best regards
Teck Boon

View Replies !
Connecting To SQL 7 Through Enterprise Manager 2000
Is it possible to connect to a SQL Server 7 remotely from a SQL 2000 Enterprise Manager. I have been given the alias config from my web hosting service but no joy on the connection.

Thanks


Anthony

View Replies !
Enterprise Manager 2000 Question
I've recently installed the sql server 2K client tools on my laptop, and I cannot figure out one portion of enterprise manager. From the taskpad overview of a database, I choose the "Table Info" tab. On certain databases, it displays the tables/rows/size information, as it did in the sql 7 version. On other databases/servers, no tables show up. I connect to all servers as sa, so I don't believe it's a permission issue. Does anyone know what I'm not doing correctly? Thanks in advance,
Jason

View Replies !
SqlServer 2000 Enterprise Manager - Major Bug?
I had a problem today where I could not see column names and alltables had a _1 after them when viewing a Sql Server view inEnterprise Managere.g.TableName Company when added to the view would be named Company_1 andthe only columns available were 1 which was *(All Columns)After looking through the news groups I saw several occurrences ofthis problem but no answers that gave a fixAfter some investigation I found that it is caused when the databasename in SqlServer has a . in it!Test1 >> Fine the view designer works fineTest1.6 >> Problems as listed aboveI don't see why Enterprise Manager allows database names with .'s ifit is going to create such problems.

View Replies !
Enterprise Manager For 2000 No Longer Loads
After installing DTS designer tools for SSIS/Visual studio,
I can no longer open enterprise manager and get the following error:

mmc.exe - entry point not found

The procedure entry poinst ?ProcessExecute@@YAXPAUXHWND_@@PBG1@Z could not be located in the dynamic link library SEMSFC.dll.

View Replies !
Help! Enterprise Manager Turns SQL Server Service Manager Off
IF someone can assist me.  Everytime I load up enterprise manager the service manager turns off.  And the enterprise manager can't connect to the local database.  But everytime i turn it back on and try to connect again it shuts it off and around and around we go.  Help would be appreciated.  Thanks.

View Replies !
SQL 2000 Enterprise Manager 'Management' Folder Empty
Hi,
We patched our servers last week and now, when connecting to our server remotely via Enterprise Manager (with DBO permissions), the management folder shows as empty.  My guess is its permission related but, I'm not sure where to begin to correct the issue since we aren’t sure how it happened.  Any help will be greatly appreciated.
~des

View Replies !
Strage Characters Displaying In Enterprise Manager 2000
HiRecently I have noticed that strange characters have begun appearingin sql server 2000 enterprise manager.Examples are:when viewing a table listing some tables may have 14:04:51 followed bya square.when performing a restore the selection of backups to restore are alldisplayed as bold pipe, bold pipe, bold pipe (which is reallyunhelpful in that situation ;)Could anyone shed some light into whats causing this? I'm actuallyquite concerned!Product version 8.00.760(SP3) running on 2003 sp1, the problem wasoccuring prior to sp1 thoThanks in advance

View Replies !
SQLServer 2000 SP4 Enterprise Manager Crashes Immediately...
Hello,I need some help with SQL Server 2000 SP4. I've been using thedeveloper product for a few years now on my PC with very few problems.Today when I try to start up Enterprise Manager, it crashesimmediately. I get the usual "Please tell Microsoft about this problem"dialog and if I click the 'click here' link, I'm presented with adialog that says:-------------------------------------------------Error signatureAppName: mmc.exe AppVer: 5.1.2600.2180 ModName: mmc.exeModVer: 5.1.2600.2180 Offset:0001f07eReporting detailsThis error report includes: blah, blah, blah...-------------------------------------------------I am running Windows XP with SP2. Also installed is Visual Studio 2003,Visual Studio 2005, and SQLServer 2005 (We're in the process ofmigration).All of these products have been running OK together for at least amonth until today. I'm not sure what changed, but obviously somethinghas. I tried uninstalling and reinstalling SQLServer 2000 & it's SP4,but no luck. Enterprise Manager still crashes immediately when I try tolaunch it.Could somebody please help me out?Thanks.

View Replies !
Cannot Access Clustered Disk Using Enterprise Manager SQL 2000
Hello,

I am running an SAP installation on clustered DELL poweredge 1850's with a shared scsi disk system. I am running Windows 2000 sp4 with sql 2000 sp4. I am trying to restore a database from a .bak file on a clustered disk. When I attempt to access the disk through enterprise manager it is not there. I only get access to the E: drive (which is clustered as well)

View Replies !
Limiting Tables Displayed In New Window For SQL 2000 Enterprise Manager
Can anyone tell me if there's a way to create new windows from thetables section of a database in Enterprise Manager such that I canlimit the tables included in that window? Ultimately, I'm looking fora solution whereby I can group tables, stored procedures, etc. intological groups that can then be displayed using different MMCconsoles. I'm looking for either a GUI-level or programatic approach.Thank you,Dax Westerman

View Replies !
Foreign Key Constraint
student --- enrollment is 1- to - many . ssn is pk in student. ssn and courseid is pk in enrollment. later I added the foreign key constraint FK_SSN in enrollment table reference student table. it is ok.
enrollment --- lessonhistory is 1-to -many, ssn, courseid and lessonid is pk in lessonhistory . I tried to set FK_SSN foreign key constraint in lessonhistory table reference enrollment table, it always show error message " no primary key in referewnce talbe enrollment "
I don't know how to fix it. could you help me out, thanks!!

View Replies !
Foreign Key Constraint
i have a publication that is composed of

many articles. The publication is composed of many

realated tables. I'm doing a snapshot replication

 

Is there a way to specify  the order by which table

must synchonize.

 

lets say. article 1 synchonizes first,  then article 3, then article 2

 

 

View Replies !
Introducing FOREIGN KEY Constraint
"Introducing FOREIGN KEY constraint 'FK__APPLICANTMA__SEX__414EAC47' on table 'APPLICANTMASTER' may cause cycles or multiple cascade paths. Specify ON DELETE NO ACTION or ON UPDATE NO ACTION, or modify other FOREIGN KEY constraints."


ive a foreign key reference on the table APPLICANT MASTER
of the form
FOREIGN KEY (SEXCODE) REFERENCES
APPLICANTSEX(SEXCODE)
ON DELETE NO ACTION
ON UPDATE CASCADE,


can any one help me WHAT THE MESSAGE MEANS ?

View Replies !
Disabling A Foreign Key Constraint
ok i build up my index and all that but how do i remove :

Enforce relationship for replication
Enforce relationship for INSERTs and UPDATEs

how do i remove that in a store proc ! ??

thanx


===========HERE MY CODE=========

CREATE TABLE [dbo].[TblTypeTaxe] (
[IdTypeTaxe] [int] IDENTITY (1, 1) NOT NULL ,
[sNomTypeTaxe] [nvarchar] (50) NULL ,
[sNomTypeTaxe_En] [nvarchar] (50) NULL ,
[sNomTaxe1] [nvarchar] (10) NULL ,
[sNomTaxe1_En] [nvarchar] (10) NULL ,
[sNomTaxe2] [nvarchar] (10) NULL ,
[sNomTaxe2_En] [nvarchar] (10) NULL ,
[nTauxTaxe1] [float] default(0) NOT NULL ,
[nTauxTaxe2] [float] default(0) NOT NULL ,
[bTaxe2SurTaxe1] [bit] default(0) NOT NULL
) ON [PRIMARY]
GO

alter table TblSalle add IdTypeTaxe int not null default(0)
go

CREATE INDEX [IX_IdTypeTaxe] ON [dbo].[TblSalle]([IdTypeTaxe]) ON [PRIMARY]
GO

ALTER TABLE [dbo].[TblTypeTaxe] WITH NOCHECK ADD
CONSTRAINT [PK_TblTypeTaxe] PRIMARY KEY CLUSTERED
(
[IdTypeTaxe]
) ON [PRIMARY]
GO

ALTER TABLE [dbo].[TblSalle] ADD
CONSTRAINT [FK_TblSalle_TblTypeTaxe] FOREIGN KEY
(
[IdTypeTaxe]
) REFERENCES [dbo].[TblTypeTaxe] (
[IdTypeTaxe]
)
go

View Replies !
DTS And Foreign Key Constraint Problem
Hi

I am attempting to write a DTS package that copies the data across from one instance of a db on a test server to a second instance on to the live server. It has to replace all the exisiting date so I can't append. Unfortunately, the package keeps giving me errors all of the type "unable to truncate tbl due to foreign key constraints". Is there a way round this?

Thanks

Steve

View Replies !
Disabling FOREIGN KEY Constraint...
sql 2000, northwind databse

code in sql analyzer:


Code:


ALTER TABLE categories NOCHECK CONSTRAINT ALL
TRUNCATE TABLE categories
ALTER TABLE categories CHECK CONSTRAINT ALL



but still i am getting the error:

Quote: Server: Msg 4712, Level 16, State 1, Line 2
Cannot truncate table 'categories' because it is being referenced by a FOREIGN KEY constraint.

what i need to do is write a query that just cleans all the tables of all data.

View Replies !
Foreign Key Constraint Issue..please Help
Hi there

Yesterday I made alot of updates to to various tables within a databse, to update some records I had to drop the foreign key constraint, but when I try to add the constraint back I get an error message (in red)
ALTER TABLE [dbo].[ITEMS] ADD
                CONSTRAINT [FK_ITEMS__ITEM_CATEGORIES] FOREIGN KEY
(
                               [ITC_ID]
                ) REFERENCES [dbo].[ITEM_CATEGORIES] (
                                [ITC_ID]
                ) ON UPDATE CASCADE  NOT FOR REPLICATION ,
                CONSTRAINT [FK_ITEMS__ITEM_TYPES] FOREIGN KEY
                (
                                 [ITY_ID]
                ) REFERENCES [dbo].[ITEM_TYPES] (
                                [ITY_ID]
                ) ON UPDATE CASCADE  NOT FOR REPLICATION
GO
Server: Msg 1785, Level 16, State 1, Line 1
Introducing FOREIGN KEY constraint 'FK_ITEMS__ITEM_CATEGORIES' on table 'ITEMS' may cause cycles or multiple cascade paths. Specify ON DELETE NO ACTION or ON UPDATE NO ACTION, or modify other FOREIGN KEY constraints.
Server: Msg 1750, Level 16, State 1, Line 1
Could not create constraint. See previous errors

any suggestions? I tried modifying the statement to ON UPDATE NO ACTION, but I get exactly the same error message.
Any help would be much appreciated...thanks in advance

View Replies !
Error FOREIGN KEY Constraint
 

Hi,
i have two tables, one is department-Table(Master table) and other is employee-table(Child table).
DNO is a data field which is common in both the table.  "DNO" is primary key in department-table and "DNO" is foreign key in child table.
 
I am trying to insert rows in the table i found the following error:
 
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_Employee_Department". The conflict occurred in database "Project", table "dbo.Department", column 'Dno'.
 
What's the solution to replace this error
 
Thanks.
 
 

View Replies !
Override A Foreign Key Constraint
A website that I'm working on has users sign in and keeps a log of the pages they go to.  The log table has a foreign key in it that links to the username is the users table.  I need to update the username for one of the users but the foreign key is preventing me from doing so.  What is the benefit of having a foreign key like this?  Can I delete it to update the username or is there a better way?

View Replies !
Need Help Adding Foreign Key Constraint
Here is my sqlce:




Code Block

alter table tblV
add constraint
foreign key (T_ID)
references tblT(T_ID)
on delete set null on update cascade
Error is:
Major Error 0x80040E14, Minor Error 25501
There was an error parsing the query. [ Token line number = 3,Token line offset = 1,Token in error = foreign ]

I'm new with SQL Mobile, so sorry for the novice question.

Thanks

View Replies !
Creating Foreign Key Constraint
I have two tables; each has multi-column primary keys.  I need to create a foreign key relationship between the two tables.
 
Sales:
DKey, int, PK
OKey,int, PK
RKey,int, PK
...

Rep:
Bkey, int, PK, identity
Rkey, int, PK
...
 
When I try to like Rkey from both tables as a foreign key relationship, I get an error that the columns in one table "do not match an existing primary key or UNIQUE constraint.  (I've tried it both ways and get the same error.)
 
How can I link these two tables?

Thanks.

View Replies !
Foreign Key Constraint Conflict
Hi,
I am fairly new to SQL server Express and I have quite a simple database set up and I am trying to test it out with data. I have €œPain Reading€? and €œWorsen Factors€? tables with a 1: M relationship. The primary key in the Pain reading table is ReadingID which is being set using getdate() for the default value. I am getting the following error when attempting to add a new row to the €œWorsen Factors€? table:
 
No row was updated
 
The data in row 1 was not committed.
Error source:.Net SqlClient Data Provider
Error Message: The insert statement conflicted with the FOREIGN KEY constraint "FK_WorsenFactor_PainReading1". The confilct occurred in database "paindata", table "dbo.PainReading", column 'ReadingID'.
The statement has been terminated.
 
Any help or suggestions would be very helpful.
 
Thanks

View Replies !
Foreign Key Constraint Error
Hi all, I'm new here so I hope this is the right place to post!!

I'm having a really big problem trying to make a table. I'm not new to the coding, but I'm no expert either.... as far as I can see I haven't done anything wrong...

I have many tables, but the first two are JobDetails and Promotions... in JobDetails, there is a primary key Job which needs to link to Promotions as a foreign key.... here is my code and errors, I'd really appreciate some help...


create table JOBDETAIL
(Job varchar2(15) primary key,
Dept varchar2(10) not null,
Salary number(7) not null);


create table PROMOTION
(PCID number(6) primary key,
PDate date,
Constraint fkey_p1 foreign key (Job) references JOBDETAIL(Job));

ERROR at line 4:
ORA-00904: "Job": invalid identifier



... any help would be appreciated, this is quite important... thank you!!!

View Replies !
Foreign Key Constraint To A Composite Primary Key
I have two tables: table 1 and table 2. The primary key of table is composite key of two collumns and table 2 is the child of parent table 1. Is it possible to create / define a foreign key constraint using a composite primary key?

View Replies !
Foreign Key Constraint- Reference 1 Of 2 Tables
Hi,
I don't know if this is possible, i believe not, so I'm here to ask the experts if is possible to have a foreign key constraint that references the key of one of two tables.
Like this:
I have 3 tables: TABLE X, TABLE A and TABLE B
Is it possible to the FK on TABLE X refernce the PK of TABLE A OR TABLE B?
If yes, how can I do this?
If not, I need to have a fourth table, so TABLE X references TABLE A and TABLE Y references TABLE B.
Thanks!

View Replies !
Determining If Foreign Key Constraint Exists
Hello,I'm working with a number of databases. I need a way to determine if aforeign key with given name exists and determine what tables andfields are linked to it. Any ideas?I know I can issue the following statement to get a list of the fieldsthat are constrained by a foreign key constraint.SELECT * FROM INFORMATION_SCHEMA.CONSTRAINT_COLUMN_USAGEHow can I get a list of fields pointed to by the constraints?Thanks,WillJoin Bytes!

View Replies !
Column Foreign Key Constraint 'EOR_ITE_REF_EOR'
I am importing data from a flat, comma delimited text file. It appears to properly import all the records and then on the last record it give me the error

INSERT statement conflicted with COLUMN FOREIGN KEY constraint for 'EOR_ITE_REF_EOR'.

Then it goes on to tell me the database, table and column in which the problem occured which is the first column in the table. It looks like it doesn't like the end of the file for some reason (EOR, end of record?) so I tried deleting the last record from the file and it still does it. I do have a file that I have imported that worked so I tried copying the last record of that file and pasting it into the last record of the file I wanted but that did not work either. The ends of file that works and the file that doesn't work look the same and I can find nothing on 'EOR_ITE_REF_EOR'. Any help would be appreciated.

View Replies !

Copyright © 2005-08 www.BigResource.com, All rights reserved