tlhunter / consumer-centric-api-design

Book on HTTP API Design, LaTeX, Creative Commons
http://amzn.to/1kcwhCo
320 stars 42 forks source link

Figure 2.1 missing employee_id field in zoo table #12

Open weinberg opened 9 years ago

weinberg commented 9 years ago

The relationship between zoos and employees is missing from the tables in Figure 2.1. The line (and the descriptive text) says that a zoo has 0 or more employees and an employee has 0 or more zoos but there is no foreign key in either zoo or employee table.

Seems like you need +employee_id in the zoo table or +zoo_id in the employee table (or both?).

Actually, I just realized you are using this notation to represent a join table. Sorry - this can be ignored. Thanks for the good read.