1. Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2012
    Rep Power

    Many-to-many table with ID and Relation?

    I'm trying to build a database where an admin

    > Can create lists that have can have tasks, now the tricky part is, all users can set tasks as completed, but only for himself.

    Here's my current scheme

    Screen Shot 2017-01-11 at 13.47.59.png
  2. #2
  3. SQL Consultant
    Devshed Supreme Being (6500+ posts)

    Join Date
    Feb 2003
    Toronto Canada
    Rep Power
    that will work if the keys are defined correctly

    the problem with database diagrams is that the generated CREATE TABLES statements may or may not include the necessary PK-FK relationships correctly

    for example, in your user_blocks and client_blocks diagram, you have some crows feet on the wrong end of their lines

    please, show us the SQL rather than the diagram
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

IMN logo majestic logo threadwatch logo seochat tools logo