InnoDB vs MyISAM: Differences InnoDB and MyISAM

Bikash Panda
2 min readApr 17, 2021

--

Major points about InnoDB and MyISAM which we discuss in this article,

  • Introduction
  • What is InnoDB and MyISAM
  • Differences Between InnoDB and MyISAM or InnoDB vs MyISAM

Introduction

There are many different types of storage engines available for MySQL index structure. Performance and features are dependent on the storage engine used under the hood of MySQL installation. Well, when there is much different storage engine it is practically impossible to discuss all of them, however, in the industry, you will mainly hear about two major storage engines InnoDB and MyISAM.

What is InnoDB and MyISAM

InnoDB is a storage engine for the database management system MySQL and MariaDB.

MyISAM is the default storage engine for MySQL relational database management system for version 5.5.

Differences Between InnoDB and MyISAM: InnoDB vs MyISAM

Here are the deep Differences Between InnoDB and MyISAM.

Before we continue learning about indexes let us compare both of them over here InnoDB is a default storage engine as of MySQL 5.5 that means when we install MySQL 5.5 or later version the default storage engine is InnoDB however before MySQL version 5.5 default storage engine was MyISAM.

  1. If you go to the real world you will see lots of insulation are using InnoDB as a storage engine and lots of installations are still using MyISAM. I personally see lots of projects where people are migrating from MyISAM to InnoDB as a default storage engine.
  2. InnoDB is ACID-compliant as it stands for Atomicity Consistency Isolation and Durability this is very crucial for data integrity.
  3. MyISAM is not ACID compliant you know to also support transactions like a rollback and commit this gives users better control of the data and its flow in their application on the other hand MyISAM is a non-transactional storage engine.
  4. MyISAM supports table-level locking whereas you know DB supports row-level locking InnoDB has more granular control of your data locking in case of InnoDB row data stored in pages is as per primary key order.
  5. It also supports foreign keys and other relationships whereas MyISAM does not support any relationship constraints MyISAM supports full-text search InnoDB does not support full-text search hence there are no full-text indexes in InnoDB.
  6. MyISAM is a great field as this is an indexing course related to performance tuning we will be using InnoDB as our default database for all the examples as well as the theory we will discuss MyISAM where and when required however our default assumption is that our storage engine is InnoDB.

To know more details about both InnoDB and MyISAM, MySQL:: MySQL 8.0 Reference Manual:: 16.2 The MyISAM Storage Engine and InnoDB — MariaDB Knowledge Base

Also Check:

Happy Coding..!

Originally published at https://phpcoder.tech on April 17, 2021.

--

--

Bikash Panda

I am a web application developer. FB Community: @mrpandatech, Twitter: @phpcodertech My PHP problem-solving site http://phpcoder.tech