if it is a straight one - to - one can't you put it all in one table? or do
you need them separate?
_______________________________________________________
* Regards,
Richard Lovelock
Westminster City Council - Web Support
Cap Gemini Ernst & Young
Southbank
95 Wandsworth Road
London
SW8 2HG
( 0870 906 7482
_______________________________________________________
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: 31 October 2003 15:23
To: [EMAIL PROTECTED]
Subject: [ cf-dev ] one-to-one relationship
This is a very simple question, but something I've never really given much
thought before. If you've got two tables with a one-to-one relationship,
how do you deal with the foreign keys? e.g. lets say you had FootballTeams
and FootballGrounds (and lets pretend there aren't any teams that share
grounds). In which table would you store the foreign key linking it to the
other table? Or would you duplicate data and store in both. e.g:
Team, GroundID
Rangers, 2
Celtic, 3
Hearts, 5
Hibs, 1
Aberdeen, 4
Ground, TeamID
Easter Road, 4
Ibrox, 1
Parkhead, 2
Pittodrie, 5
Tynecastle, 3
I'm sure there's a logical rule for dealing with this, but I can't think
what it is. Not a very difficult issue, just something I'm pondering.
Duncan Cumming
IT Manager
http://www.alienationdesign.co.uk
mailto:[EMAIL PROTECTED]
Tel: 0141 575 9700
Fax: 0141 575 9600
Creative solutions in a technical world
----------------------------------------------------------------------
Get your domain names online from:
http://www.alienationdomains.co.uk
Reseller options available!
----------------------------------------------------------------------
----------------------------------------------------------------------
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]
=======================================================
This message contains information that may be privileged or confidential and is the
property of the Cap Gemini Ernst & Young Group. It is intended only for the person to
whom it is addressed. If you are not the intended recipient, youare not authorized to
read, print, retain, copy, disseminate, distribute, or use this message or any part
thereof. If you receive this message in error, please notify the sender immediately
and delete all copies of this message.
=======================================================
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]