1. We have moved to a new forum! There may be a few things not working properly so please let us know if you find a bug. Remember to use the bbCode [ sql ] tag for SQL statements.

Simple templates by user listing?

Discussion in 'SQL - Questions and Answers' started by josoroma, Mar 7, 2007.

  1. josoroma New Member

    Dialect: MySQL
    Hi!
    My english is a shame.

    I got two tables, Users and Listings, for example:

    Users
    id
    ...

    Listings
    id
    user_id
    ...

    A user can have and manage more than one listing in the directory.

    Now i need to associate a user listing to a template:

    Templates
    id
    listing_id

    Do i have to add user_id in Templates table or the listing_id is the good relationship, because a template belongs to a listing and a listing to a user?

    Thnaks in advanced.

Share This Page