SitePoint Sponsor

User Tag List

Results 1 to 13 of 13
  1. #1
    SitePoint Enthusiast
    Join Date
    Feb 2013
    Posts
    35
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Novice to Ninja Chapter 2: Syntax problems with phpmyadmin

    Was able to complete all exercises until I tried typing the command "DESCRIBE joke" (without quotes) which gives me ERROR #164 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'index' at line 1. Also tried "DESCRIBE joke;". Had same problem with SELECT command. Using OSX 10.8.5, set up server with MAMP as outlined in book. Also, when I access the home page for phpmyadmin there's a notice that I don't have the latest version (4.0.8) which I've downloaded but I don't know what to do with it.

  2. #2
    From Italy with love silver trophybronze trophy
    guido2004's Avatar
    Join Date
    Sep 2004
    Posts
    9,492
    Mentioned
    161 Post(s)
    Tagged
    4 Thread(s)
    So you entered the sql command 'DESCRIBE joke' in phpMyAdmin, and the message says you have an error near 'index' at line 1 ? That's weird, because there is no 'index' in 'DESCRIBE joke' ...

  3. #3
    SitePoint Enthusiast
    Join Date
    Feb 2013
    Posts
    35
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Sorry....i named my table index and used it in the commands

  4. #4
    Hosting Team Leader silver trophybronze trophy
    cpradio's Avatar
    Join Date
    Jun 2002
    Location
    Ohio
    Posts
    5,050
    Mentioned
    152 Post(s)
    Tagged
    0 Thread(s)
    Sigh, first off, that was a mistake as index is a keyword. But to get around this blunder use the following (using back ticks so MySQL knows you are not inferring the keyword):
    Code:
    DESCRIBE `index`
    Be sure to congratulate Patche on earning July's Member of the Month
    Go ahead and blame me, I still won't lose any sleep over it
    My Blog | My Technical Notes

  5. #5
    SitePoint Enthusiast
    Join Date
    Feb 2013
    Posts
    35
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Thank you! I renamed the table and was able to execute the commands. Any advice for upgrading phpmyadmin to 4.0.8?

  6. #6
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,215
    Mentioned
    58 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by cpradio View Post
    Sigh
    indeed

    pro tip to OP and all others who might read this thread: please do not use fake names

    it wastes your time and annoys the pig (that's an old punch line, not an insult)
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  7. #7
    Hosting Team Leader silver trophybronze trophy
    cpradio's Avatar
    Join Date
    Jun 2002
    Location
    Ohio
    Posts
    5,050
    Mentioned
    152 Post(s)
    Tagged
    0 Thread(s)
    Are you using XAMPP, WAMP, MAMP? Any of those, none of those?
    Be sure to congratulate Patche on earning July's Member of the Month
    Go ahead and blame me, I still won't lose any sleep over it
    My Blog | My Technical Notes

  8. #8
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,215
    Mentioned
    58 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by nerves View Post
    Any advice for upgrading phpmyadmin to 4.0.8?
    yes

    try heidisql instead

    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  9. #9
    SitePoint Enthusiast
    Join Date
    Feb 2013
    Posts
    35
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Are you using XAMPP, WAMP, MAMP? Any of those, none of those?
    MAMP

  10. #10
    Hosting Team Leader silver trophybronze trophy
    cpradio's Avatar
    Join Date
    Jun 2002
    Location
    Ohio
    Posts
    5,050
    Mentioned
    152 Post(s)
    Tagged
    0 Thread(s)
    Okay, start with this: http://blog-en.mamp.info/2013/08/how...mamp-mamp.html

    If you get stuck, let us know, but it looks to be straight forward.
    Be sure to congratulate Patche on earning July's Member of the Month
    Go ahead and blame me, I still won't lose any sleep over it
    My Blog | My Technical Notes

  11. #11
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,215
    Mentioned
    58 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by nerves View Post
    MAMP
    okay, sorry, no heidisql for you
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  12. #12
    SitePoint Enthusiast
    Join Date
    Feb 2013
    Posts
    35
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by r937 View Post
    okay, sorry, no heidisql for you
    thanks anyway!

  13. #13
    SitePoint Enthusiast
    Join Date
    Feb 2013
    Posts
    35
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by cpradio View Post
    Okay, start with this: http://blog-en.mamp.info/2013/08/how...mamp-mamp.html

    If you get stuck, let us know, but it looks to be straight forward.
    Thank you! The main instructions were a bit confusing since I didn't install MAMP PRO but the method given by Charles Butcher (see below) in the comments worked fine.

    "The following worked for me with 10.8.5, MAMP 2.2 and phpMyAdmin 4.0.8:

    1. Rename /Applications/MAMP/bin/phpMyAdmin to "phpMyAdmin_old".

    2. Move the newly-downloaded phpMyAdmin folder into /Applications/MAMP/bin/ and rename it "phpMyAdmin".

    3. Copy /Applications/MAMP/bin/phpMyAdmin_old/config.inc.php to /Applications/MAMP/bin/phpMyAdmin/

    Might be different if you are running MAMP Pro."


Tags for this Thread

Bookmarks

Posting Permissions

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