Feedback wanted to improve the database ERD

Feedback wanted to improve the database ERD
0.0 0

#1

I’m looking for feedback about the ERD (see below) to make it a valid ERD able and the constraints mentiond below.
What and why do i need what to edit in the ERD? See page 2.
Put your feedback in the comments via Google Drive. Thank you.

Do I need to change the FK between (verzekering)entity inshurense and (verhuur) entity rent table?
Or do I add a FK to the verhuur (rent) entitiy so it’s unique to add the FK relationship fiets_id in the entity verzekering?

Constraints:

  1. Only the Bikes (fiets) have inshurence.

  2. Bikes are able to swap if there is a spare, not recerverd bike < so i twill be a stored procedure

  3. email is unique < ‘’ “

  4. Six relevant check constraints (via stored procedures)

  5. insert rules:

  • email must be unique,
  • rent date must be on or after the current date
  1. Update constrains:
  • cannot subscribe if email is NULL
  • cannot change ID
  • returns a error if the ID does not exist
  1. Delete Rules:
  • can only delete one record at a time
  • maintain a log who deleted an when

Looking for your replay,

Best,
Rick