1. #1
    illfuuptn
    illfuuptn's Avatar Become A Pro!
    Join Date: 03-17-10
    Posts: 1,860

    mysql question

    I want to do a typical
    Code:
    Update table x insert values(1,2,3...)
    but I want the 1st value in parentheses to be put in the 30th field column. Then the second in the 31st and so on. It obviously usually defaults to putting the first value in the first column, 2nd in 2nd column, etc.

  2. #2
    MonkeyF0cker
    Update your status
    MonkeyF0cker's Avatar Become A Pro!
    Join Date: 06-12-07
    Posts: 12,144
    Betpoints: 1127

    Is this a serious question?

    Uhh. You just answered your own question.

  3. #3
    bink
    bink's Avatar Become A Pro!
    Join Date: 10-15-11
    Posts: 36
    Betpoints: 875

    UPDATE and INSERT INTO are two different SQL statements. You can't have them in the same query.

    So if you're just updating existing rows use UPDATE (ex. UPDATE table SET column=value WHERE otherColumn = someValue) or if you're adding new rows use INSERT INTO (ex. INSERT INTO table (columns) VALUES (values)).

    If you're trying to add new columns into an existing table then you'll need to use the ALTER statement (ex. ALTER TABLE table ADD column AFTER column) and then UPDATE the values of the new columns.

  4. #4
    MonkeyF0cker
    Update your status
    MonkeyF0cker's Avatar Become A Pro!
    Join Date: 06-12-07
    Posts: 12,144
    Betpoints: 1127

    Are you incapable of using a search engine?

    That's a serious question.

    There's no possible way that you could have found that update syntax if you actually bothered looking.

  5. #5
    illfuuptn
    illfuuptn's Avatar Become A Pro!
    Join Date: 03-17-10
    Posts: 1,860

    Quote Originally Posted by MonkeyF0cker View Post
    Are you incapable of using a search engine?

    That's a serious question.

    There's no possible way that you could have found that update syntax if you actually bothered looking.
    I actually googled the shit out of it and nothing came up, baby doll.

  6. #6
    MonkeyF0cker
    Update your status
    MonkeyF0cker's Avatar Become A Pro!
    Join Date: 06-12-07
    Posts: 12,144
    Betpoints: 1127

    Quote Originally Posted by illfuuptn View Post
    I actually googled the shit out of it and nothing came up, baby doll.
    Nothing came up for "sql update"???

    You're kidding, right?

    I only get 161,000,000 hits.

  7. #7
    MonkeyF0cker
    Update your status
    MonkeyF0cker's Avatar Become A Pro!
    Join Date: 06-12-07
    Posts: 12,144
    Betpoints: 1127

    How about SQL tutorial??

    SQL syntax?

    SQL commands?

    What on Earth were you searching for?

  8. #8
    illfuuptn
    illfuuptn's Avatar Become A Pro!
    Join Date: 03-17-10
    Posts: 1,860

    Maybe you should actually read the whole op, fuhkface.

  9. #9
    MonkeyF0cker
    Update your status
    MonkeyF0cker's Avatar Become A Pro!
    Join Date: 06-12-07
    Posts: 12,144
    Betpoints: 1127

    Quote Originally Posted by illfuuptn View Post
    Maybe you should actually read the whole op, fuhkface.
    Uhh. I read your nonsensical post.

    So you decided to google imaginary SQL statements instead of trying to read a tutorial and find the actual commands and syntax? Is that what you're saying?

    Brilliant.

  10. #10
    strixee
    I think, therefore I win
    strixee's Avatar Become A Pro!
    Join Date: 05-31-10
    Posts: 432

    All right, illfuuptn it's good you have a sense for humor, but better post in PT.

  11. #11
    mikeanite
    mikeanite's Avatar Become A Pro!
    Join Date: 04-13-10
    Posts: 475
    Betpoints: 582

    atleast you know how it feels to be a newbie and no one wants to help you. been feeling this for awhile

  12. #12
    Maverick22
    Maverick22's Avatar Become A Pro!
    Join Date: 04-10-10
    Posts: 807
    Betpoints: 58

    I don't see where you read that noone was trying to help him

  13. #13
    mikeanite
    mikeanite's Avatar Become A Pro!
    Join Date: 04-13-10
    Posts: 475
    Betpoints: 582

    feed him enough cheese to keep him going. if this was in the early 2000's ppl were more willing to share their methods openly cuz they were still trying to learn like the rest of us.

  14. #14
    Maverick22
    Maverick22's Avatar Become A Pro!
    Join Date: 04-10-10
    Posts: 807
    Betpoints: 58

    Help and hand holding are two different things
    Last edited by Maverick22; 04-03-12 at 10:06 AM.

Top