sneidr rider wrote:
> hi all -
> i'm fairly new to all this database stuff and was wondering if i could clear
> few things up here. how can i implement the foreign key feature, and what
> does this mean? what is the difference between unique and key?? lastly, how
> do i implement the index feature and what does this mean??? any tips or
> pointers would be greatly appreciated. i've read a bunch of the tutorials,
> but none seem to cover these details very deeply.
> thanx -
Usually you don't need FOREIGN KEYs.
Mysql only understands the FOREIGN KEY syntax, but doesn't do anything with it.
If you mean, how to make SELECT's which have references between different tables, you have
to look at the JOIN syntax.
A KEY generates an index, which is used to speedup searches.
A UNIQUE is a key which takes care, that each entry in this index occures only once.
So if you try to insert one value multiple times into a UNIQUE key field, you will get a
"duplicate key error".
A PRIMARY KEY is the first UNIQUE key created in a table.
INDEX is only another name for KEY.
|• help me please?!||sneidr rider||9 Jun|
| • Re: help me please?!||Christian Mack||10 Jun|