HiveBrain v1.2.0
Get Started
← Back to all entries
patternsqlMinor

Will a change from MyISAM to InnoDB require SQL query changes in MySQL?

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
sqlinnodbquerymysqlwillchangesmyisamrequirefromchange

Problem

I am planning to change some large MyISAM tables in my MySQL database into InnoDB.

This is because I am having performance problems where large and complex updates (updating a few million rows in one go) are stopping users from concurrently accessing that tables.

I understand that if I convert the table to InnoDB then the writes/updates will cause row locking rather than table locking.

If I do this, Will have have to review all my SQL selects/insert statements, and my stored procedures, and make any changes due to the engine change, or will they all 'just work'?

Solution

I don't think you need to change any SQL statements and SP's, They should work as they were before.

You need to keep in mind some points

-
If you have MySQL version 5.5 or below and you have FULL TEXT index on Table then this is a issue, InnoDB doesn't support FULL TEXT index up to MySQL 5.5, They are supported in MySQL 5.6 and above.

-
If you have Spatial Indexes on table, They are yet not supported in InnoDB engine

There are a lot of other points that you should keep in mind are, Please must have a look at some great links which suggest what are various things you should consider in migrating table from MyISAM to InnoDB

-
What are the main differences between InnoDB and MyISAM.?

-
How do you tune MySQL for a heavy InnoDB workload. ?

-
Should I move to InnoDB during a planned migration. ?

-
Online conversion from MyISAM to InnoDB ?

-
Converting Tables from MyISAM to InnoDB.

Context

StackExchange Database Administrators Q#55921, answer score: 5

Revisions (0)

No revisions yet.