Hi
If you are inserting data into the referenced table ("primary"!) then by
definition there will be no entries in the referencing table ("foreign
key"!). If you are entering data in the referencing table then there must be
a corresponding entry in the referenced table.
If you update the referenced fields in the referenced table, you will need
to specify UPDATE CASCADE on the foreign key definition to propagate the
changes. (See CREATE TABLE in Books online).
John
<ti**********@hotmail.com> wrote in message
news:5b**************************@posting.google.c om...
Hi
Im a sql newbie , and have created two tables with a foreign key
relationship.
How do i insert into these tables. If i insert into the primary table
will the foreign key field in the second table be automaticly updated
by ms sql server ?