-3

I've got a question why someone would use MyISAM instead of InnoDB engine in MySQL. My findings so far are that default engine is InnoDB, database created is as InnoDB and also 2 of 3 tables are created as InnoDB. Just one table is working as MyISAM. Unfortunately I didn't created them and the person who's done developing is not available anymore. Is anyone has the case like that where MyISAM is really critical to use for certain type of data?

Thanks, Andre

andre
  • 1
  • 1
  • Read about [Storage Engines](http://dev.mysql.com/doc/refman/5.1/en/storage-engines.html) and [How to Convert from MyISAM to InnoDB](http://dev.mysql.com/doc/refman/5.6/en/converting-tables-to-innodb.html) – gtgaxiola Jan 13 '14 at 16:59
  • as far as i know, MyISAM is faster/lighter for simple plain tables. – bansi Jan 13 '14 at 17:00
  • 1
    possible duplicate of [MySql: MyISAM vs. Inno DB!](http://stackoverflow.com/questions/277440/mysql-myisam-vs-inno-db) – Markus Malkusch Jan 13 '14 at 17:02
  • Because they didn't need the functionality that InnoDB provides enough to absorb the cost of it. – Tony Hopkinson Jan 13 '14 at 17:14
  • 1
    This is covered in quite a lot of details in http://stackoverflow.com/questions/20148/myisam-versus-innodb – jeremycole Jan 15 '14 at 07:27

1 Answers1

-1

Using InnoDB is good is you're making lots of changes to tables (per record locking) and/or if you need foreign keys (affecting changes to tables indirectly to keep them in sync).

MyISAM is great if you have, for example, a web site that make many reads from the tables to provide content - it's far more efficient.

Emo Mosley
  • 525
  • 3
  • 9
  • Hmm... Erno, just to add to your comments as you might be right. I found out also the table is used to generate some reports (lots of readings - select statements). But before read you need to insert some records, so not sure when you can decide which engine is better. I'm assuming it could be just personal view of future use of database / table as over the time writes can be higher than reads and in other way around. – andre Jan 13 '14 at 18:21
  • @andre - From what I understand, if a web site has the kind of traffic that requires lots of small changes to one or more tables, InnoDB is the way to go, but if there's not a lot of traffic making changes, MyISAM is best. Hope that helps. :) – Emo Mosley Jan 13 '14 at 18:25
  • Erno... would you consider this as a problem of using MyISAM if we take on board the current versions of MySQL. I've read about this and so far I can see that now there won't be huge difference as InnoDB is much better now than it was in the past. Thanks a lot for your input as well. – andre Jan 14 '14 at 09:42
  • @andre - I think it's always best to use the most current version, provided it's convenient to do so. The more recent versions of MySQL have made great improvements to InnoDB, but MyISAM works just as well if not better. – Emo Mosley Jan 14 '14 at 17:26
  • 1
    I would not really consider MyISAM as universally "far more efficient" than InnoDB. They have different data structures and different optimizations, but one is not universally "more efficient" than the other. There are in fact many use cases where InnoDB will be dramatically more efficient than MyISAM, such as when clustered primary keys can be put to good use. – jeremycole Jan 15 '14 at 21:09
  • I would only say - in my experience, on a single server, MyISAM performs better in situations where many queries are made for getting data from tables to web pages (no changes made to tables). – Emo Mosley Jan 16 '14 at 14:38