在数据库设计过程中一般要遵循第一范式、第二范式、第三范式以及BCNF范式、第四范式。那么请你改正下面的数据库设计中的不足之处。
条件:设R(BOOK_ID,BOOK_NAME,AUTHOR,AGE)的属性分别表示为书号、书名、作者、和作者的年龄。如果约定:每一个书号对应一个书名:但不同的书号可以有相同的书名:每本书可以有多个作者合写:但每个作者参与编写的图书的书名应该互不相同。原来的数据库模型:
数据库表名:BOOK_INFORMATION
 
BOOK_ID     BOOK_NAME                           AUTHOR             AGE
1 SQL SEEVER2000轻松进级 Mike Gunderloy ; MaryChipman 45 ; 38
2 …… …
3 …… …
a) 你的设计模型:(列出数据表名、相应的字段名、约束)b) 从你设计的数据库总列出所有作者年龄大于40岁的图书名称c) 把一个书名为《精通SQL》的作者改为“Tom” 

解决方案 »

  1.   

    1:
    表bookinfo
    bookid    pk  identity(1,1)
    book_name表authorinfo
    authorid   pk identity(1,1)
    authorname
    age表auther2book
    id     pk identity(1,1)
    autherid
    bookid2:
    select bookinfo.name from bookinfo inner join auther2book on 
    auther2book.bookid=bookinfo.bookid inner join autherinfo on
    autherinfo.id=auther2book.autherid where autherinfo.age > 403:
    update autherinfo set name='Tom'
    where id in (select bookinfo.autherid from auther2book inner join bookinfo on
    auther2book.bookid=bookinfo.bookid where bookinfo.name='《精通SQL》')