switching from myisam to innodb

Discussion in 'MySQL' started by incognito1, Feb 11, 2011.

  1. #1
    I was thinking about switch I had a two questions.

    1. is the sql syntax the same? in terms of programming and php scripts whats different about them

    2. how is innodb faster?

    Im hoping someone can answer in layman's terms.
     
    incognito1, Feb 11, 2011 IP
  2. jkl6

    jkl6 Peon

    Messages:
    70
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    1. same syntax, no difference at all.
    2. myisam is usually faster than innodb.
     
    jkl6, Feb 11, 2011 IP
  3. georgiivanov

    georgiivanov Member

    Messages:
    62
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    25
    #3
    Have in mind that InnoDB does NOT support full-text indexes.
     
    georgiivanov, Feb 12, 2011 IP
  4. jemagee

    jemagee Peon

    Messages:
    9
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    WHat is your reason for changing - there are a couple functional differences between the two. Why would you change in the first place?
     
    jemagee, Feb 12, 2011 IP
  5. mwasif

    mwasif Active Member

    Messages:
    816
    Likes Received:
    23
    Best Answers:
    1
    Trophy Points:
    70
    #5
    mwasif, Feb 12, 2011 IP
  6. jestep

    jestep Prominent Member

    Messages:
    3,659
    Likes Received:
    215
    Best Answers:
    19
    Trophy Points:
    330
    #6
    Out of the box MyISAM is usually faster. With even mediocre configuring, InnoDB should easily outperform myisam. MyISAM has virtually zero performance benefit no matter how well you can tune it. Innodb allows for extensive customizing. If you understand how to configure the database for your specific usage, Innodb is almost always going to be a better match. The biggest drawback of Innodb is that it does not support full text indexing.

    The biggest reason to switch, are tuneability, ACID compliance, foreign keys, row level locking. If you do not understand how to configure an Innodb database then you can end up with significant performance problems. Innodb does not work as well out of the box as MyISAM. Most of the MyISAM posts that suggest it is faster are comparing out of the box configurations, or the user does not know how to setup innodb for their specific usage. Also, Innodb is often more memory intensive than MyISAM, so on very limited hardware it may be difficult to get working at an optimum speed.

    There's a ton of resources online about how to configure innodb and myisam databases.
     
    jestep, Feb 14, 2011 IP