Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder
    Join Date
    Aug 2006
    Location
    UK, London, Dartford
    Posts
    221
    Thanks
    3
    Thanked 14 Times in 14 Posts

    RPG Query 3 Tabels so confused. (Urgent)

    Tabels: user_accounts, user_items & game_items.

    Discription of Tables:
    User_accounts: Need to get uername and exprience.
    User_items: From user_items grad the ID of user items (itemid 1-4)
    game_items: from the user_items id 1-4 get the stats from game_items useing the id's

    Then ad all the exprience from the game_items to current exprience then update it.

    Sounds really hard i've had a few go but i carnt figer it out.

  • #2
    Super Moderator guelphdad's Avatar
    Join Date
    Mar 2006
    Location
    St. Catharines, Ontario Canada
    Posts
    2,634
    Thanks
    4
    Thanked 148 Times in 139 Posts
    so show us what you have attempted and you can most likely get a solution to what you are looking for.

  • #3
    Regular Coder
    Join Date
    Aug 2006
    Location
    UK, London, Dartford
    Posts
    221
    Thanks
    3
    Thanked 14 Times in 14 Posts
    Well, so fair i got this:
    PHP Code:
    $query mysql_query("SELECT u.username, u.experience, i.itemid1, i.itemid2, i.itemid3, i.itemid4 FROM user_accounts u, user_items i WHERE i.username = u.username") or(die(mysql_error())); 
    But i still gotta get it to get the item from game_items useing the itemid1-4.

    But i wont the itemid 1-4 to represent the id for the game_items ID. so i need to modify that SQL Statment


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •