Reputation: 61
AUTHOR
table
Author_ID
, PKFirst_Name
Last_Name
TITLES
table
TITLE_ID
, PKNAME
Author_ID
, FKDOMAIN
table
DOMAIN_ID
, PKNAME
TITLE_ID
, FKREADERS
table
READER_ID
, PKFirst_Name
Last_Name
ADDRESS
CITY_ID
, FKPHONE
CITY
table
CITY_ID
, PKNAME
BORROWING
table
BORROWING_ID
,pkREADER_ID
, fkTITLE_ID
, fkDATE
HISTORY
table
READER_ID
TITLE_ID
DATE_OF_BORROWING
DATE_OF_RETURNING
Upvotes: 6
Views: 1349
Reputation: 2732
An additional thought that occurred to me after reading others comments is.
If so you may have redundant first and last names entered into your system, and it would be susceptible to update anomalies. For example if Jane Smith was a reader and an author and got married and her Surname changed to Williams then the possibility for updating her Reader last name and not her author last name would exist.
You would fix this by perhaps creating a User table where you have two Foreign keys for a Authors and Readers Table. Just a thought... ;)
Upvotes: 0
Reputation: 18408
How do you expect anybody to seriously answer this question without any knowledge of your business domain ?
In order to answer this question earnestly, one needs to know the entire set of functional dependencies that govern your data, and you have not provided those.
For your scheme to be in 3NF, for example, it would require that domainID -> titleID, or, in other words, that there is only one title for each domain, and that knowing the domain implies that you can know the title. On the face of it, that seems curious, but the only one who can tell for sure whether or not this is an accurate representation of the business reality that you're dealing with, is you.
Upvotes: 1
Reputation: 2865
This looks a bit like a homework problem, but let me answer anyway:
Upvotes: 2
Reputation: 166396
I would change the Titles to a MANY-TO-MANY, and leave the addresses.
TITLES
table
TITLE_ID
, PKNAME
TitleAutors
table
TITLE_ID
,AUTHOR_ID
You could change the BORROWING table to have the status of the entry (OUT, IN, MISSING, UNKNOWN) and have a STATUS_DATE.
Upvotes: 1