Nils,
Thanks. I will code accordingly.
Carlos
>
> Hi Carlos,
>
> I believe that would have to be 2 separated steps.
>
> 1) creating the value in the primary key and
> 2) creating the foreign key value
>
> However you can use UNION to write both statements in one go.
>
> Best regards
>
> Ni
Hi Carlos,
I believe that would have to be 2 separated steps.
1) creating the value in the primary key and
2) creating the foreign key value
However you can use UNION to write both statements in one go.
Best regards
Nils Valentin
Tokyo/Japan
2003年 7月 26日 土曜日 05:20、Write a Friend さんは書きました:
>
I am a newbie to db.
I have a few tables, one that I define the primary key.
CREATE TABLE member (
memid INT(6) UNSIGNED ZEROFILL DEFAULT '002000' NOT NULL AUTO_INCREMENT,
last VARCHAR(20) DEFAULT '' NOT NULL,
first VARCHAR(20) DEFAULT '
I would just add a few words to Nils' excellent reply:
In the most general sense, a foreign key is just a primary
key value that occurs outside of its native table (i.e. in
a "foreign" table, get it?) in order to point to the record
in its native table with that value as its primary key.
You c
Hi Eli,
The short answer is .. you create relationships between tables by creating
foreign keys and primary keys. However, you might not even need them ;-) - I
explain below.
Foreign keys and primary keys are used to create relations between tables.
Using them will bind you to some rules whic