|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
Hello.
I am building a Er Digram for a Library and I have the following problem : I have an entity Member (superclass) and entitities: professor, undergraduate student, postgraduate student (subclasses of Member) and the entity Book. I have the relationship : Memebe r--> borrows <--Book and Borrowing Date and Date of Return (90 days max) are kept as attributes at the relationship. But each Member of the library has different rights at borrowing. A profeessor an borrow up to 10 books at the same time for 90 days, a postgraduate student 7 books for 60 days etc. Should I make a new entity with the rights of borrowing and each member of the library should be connected with it ? The actual numbers (10 books, 90 days) will appear somewhere or I will have attributes "number o books allowed", "days allowed" ? In addition a professor can reserve up to 5 books. Wiill this number appear in the ER-diagram Any help should be valuable to me. Thank you in in advance for your time and patience |
|
#2
|
|||
|
|||
|
Without know all the facts, my suggestion would be that you have 4 entities, i.e. Member, Staff Type, Terms and Book.
The one-to-many relationships would be :- a) Terms : Staff Type b) Staff Type : Member c) Member : Book I hope that gives you some 'food for thought' |
|
#3
|
|||
|
|||
|
Actually, I think maria's on the right track using subtype entities; this is a classic example of their usage which you have different type of people to track. You could have a relationship between each different type of member and borrows giving each relationship a different cardinality.
__________________
. |
|
#4
|
|||
|
|||
|
i think it is better to make "number o books allowed" and "days allowed" to be the attrbutes of each type of member!
The method of attaching cardinality to the borrow relationship is not practical since the user may not borrow maximum number of books at one time! |
![]() |
| Viewing: Dev Shed Forums > Databases > Database Management > ER Diagram |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|