Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
zippy
Yak Posting Veteran
69 Posts |
Posted - 2002-01-17 : 03:43:39
|
| Hi,I was just wondering if anybody new a fancy/easy way to check to see if a record is being used as foreign key in another table.I don't want to see if there is actually a relationship between them, I want to check if a particular record is being related to.Hope that makes sense?ThanksCheck out the worlds fastest computers at http://www.ocgurus.com |
|
|
AndrewMurphy
Master Smack Fu Yak Hacker
2916 Posts |
Posted - 2002-01-17 : 07:06:56
|
| best way is probably to work with the information_schema....this has come up here before....have a search or there may even be an article or FAQ on it....if 2 columns aren't formally linked through a FK/PK relationship...but have common data or (with maybe a similar name) then you have a bigger problem...in that for any once column you would have to check all like typed/sized columns in the database for searching on a possible match....(and i certainly hope you're not talking about this possibility...as i don't think any solution would be zippy (excuse the pun)) |
 |
|
|
|
|
|