NEED HELP and GUIDANCE!

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • new_GUY

    NEED HELP and GUIDANCE!

    I have a HUGE project (at least for me) and need some guidance.

    I am trying to create a database for a local university movie club
    that allows users to input there basic personal information (name,
    address, telephone number) as well as movies in there collection. The
    movies will be categorized by genre (comedy, romance, horror, etc.)
    and title. I want to be able to let the users add and remove movies
    to their list of movies they own, I'll call it "MOVIES I OWN".

    The user will also need to be able to create a SECOND list of movies
    they would like to see, again they can choose by genre and title.
    They need to also be able to add and remove from this list also, i'll
    call it "MOVIES I WANT TO SEE".

    The last part of the project will be to match the users of "movies i
    want to see" with "movies I own" users. It will be displayed on the
    local university website when the user logs in and will alert the user
    to the match. If there is a match at a later time, maybe the user can
    be emailed? Also if there is a match, perhaps the two movies can be
    taken off record after the user acknowledges the match. I would need
    it to be able to handle a small amount of users now logged in at the
    same time , but would like for it to eventually handle several hundred
    users logged on at the same time in the distant future with out
    performance problems.

    I am not sure if sql 2000 is the best to get this done or perhaps
    oracle. I am currently trying this on mySQL with PHP but currently am
    lost in a forest of data. Any guidance suggestions will be greatly
    appreciated. I am pretty new to this so please be kind...
  • David Portas

    #2
    Re: NEED HELP and GUIDANCE!

    Somthing like this maybe:

    CREATE TABLE Members (login VARCHAR(10) NOT NULL PRIMARY KEY, membername
    VARCHAR(30) NOT NULL UNIQUE);

    CREATE TABLE Movies (cat_no CHAR(10) NOT NULL PRIMARY KEY, title VARCHAR(30)
    NOT NULL, released INTEGER NOT NULL, UNIQUE (title,released ));

    CREATE TABLE MembersMovies (login VARCHAR(10) NOT NULL REFERENCES Members
    (login), cat_no CHAR(10) REFERENCES Movies (cat_no), media CHAR(3) NOT NULL
    CHECK (media IN ('DVD','VHS')), Memberstatus CHAR(1) NOT NULL CHECK
    (Memberstatus IN ('H','W') /* "Has" or "Wants" */), PRIMARY KEY
    (login,cat_no,M emberstatus));

    Query: Who has the movies that member 'X' wants?:

    SELECT U.membername, M.title, M.released
    FROM MembersMovies AS H,
    MembersMovies AS W,
    Movies AS M,
    Members AS U
    WHERE H.cat_no = W.cat_no
    AND H.media = W.media
    AND H.Memberstatus = 'H'
    AND W.Memberstatus = 'W'
    AND W.login = 'X'
    AND W.cat_no = M.cat_no
    AND H.login = U.login ;
    I am not sure if sql 2000 is the best to get this done or perhaps
    oracle. I am currently trying this on mySQL with PHP but currently am
    Any of those products should be capable of your specified requirements. I
    expect your choice will be guided mostly by what you know and the existing
    environment you have to work with.

    --
    David Portas
    SQL Server MVP
    --


    Comment

    • Simon Hayes

      #3
      Re: NEED HELP and GUIDANCE!

      dahct@yahoo.com (new_GUY) wrote in message news:<c978d8cf. 0406131603.34ed ddc9@posting.go ogle.com>...
      I have a HUGE project (at least for me) and need some guidance.
      >
      I am trying to create a database for a local university movie club
      that allows users to input there basic personal information (name,
      address, telephone number) as well as movies in there collection. The
      movies will be categorized by genre (comedy, romance, horror, etc.)
      and title. I want to be able to let the users add and remove movies
      to their list of movies they own, I'll call it "MOVIES I OWN".
      >
      The user will also need to be able to create a SECOND list of movies
      they would like to see, again they can choose by genre and title.
      They need to also be able to add and remove from this list also, i'll
      call it "MOVIES I WANT TO SEE".
      >
      The last part of the project will be to match the users of "movies i
      want to see" with "movies I own" users. It will be displayed on the
      local university website when the user logs in and will alert the user
      to the match. If there is a match at a later time, maybe the user can
      be emailed? Also if there is a match, perhaps the two movies can be
      taken off record after the user acknowledges the match. I would need
      it to be able to handle a small amount of users now logged in at the
      same time , but would like for it to eventually handle several hundred
      users logged on at the same time in the distant future with out
      performance problems.
      >
      I am not sure if sql 2000 is the best to get this done or perhaps
      oracle. I am currently trying this on mySQL with PHP but currently am
      lost in a forest of data. Any guidance suggestions will be greatly
      appreciated. I am pretty new to this so please be kind...
      From the information you've given, it sounds like the database
      platform is more or less irrelevant - if you're "lost in a forest of
      data", then you probably need to spend some time looking at your
      requirements and your data model. You might want to start by searching
      Google for existing data models for CD or movie collections, then look
      at extending them to allow for multiple users.

      I wouldn't worry too much about the database - your application sounds
      like many other PHP/MySQL ones (web-based, low budget, few users, no
      critical data etc.). Unless you have some clear and compelling reason
      for moving to a different database, that's likely to be a distraction
      from addressing your key issues.

      Simon

      Comment

      Working...