Re: Database Design Problem...
Posted in 1998
Topics: General Discussion
On 10 Mar 1998 04:39:06 GMT, "Birdman" <fanjun@writeme.com> wrote: Hi, what's about a so common book as the 'Holy Bible'? Ther may be a catholique revision an Amish revison and so on. How to distinguish these books other than by an artificial unique key. to use a key that has something to do with the books or the book market hat's about the ISBN as primary key? Don't now how ISBN's handle revisions. >Hi, Jimmy: > >I think it is better that you use book_name as primary key instead of >book_id. But you should not delete book_id in both table. You still use it >just as a foriegn key to manipulate tables. It is easy and handful way and >possibly saving space. The benefit using book_name as primary key is, when >you wrongly register new books with name already existing in your table, >database server will be promting you error occurs, wherease, if you use >book_id as primary key, unless you define additional index on book_name, >database server will not find it is an error. In your case, I think the >index on book_name is possibly necessary. So, making the name primary, you >could get more advantages. > >Regards > -- Regards Matthias Gresz :-) GreMa@T-online.de