4 ms·
Wait... why? Admittedly I'm mostly using MSSQL, but joining multiple tables seems a pretty natural thing to do (assuming you are joining on well indexed tables
by cogman10 3y ago
Wait... why?
Admittedly I'm mostly using MSSQL, but joining multiple tables seems a pretty natural thing to do (assuming you are joining on well indexed tables).
- Izkata 3y agoTable locks. This is specific to the default MyISAM engine, where it locks all tables used in a query for the duration of the query. So two queries that touch the same table can't run concurrently. You may never hit this as a problem if your queries are fast enough, but it is something to be aware of.
- cogman10 3y agoDidn't MySQL switch to InnoDB as the default engine a long time ago (my googling says 2010)? Does InnoDB have the same limitations?
- Izkata 3y agoI actually didn't realize they switched (we're still on an ancient version and unable to upgrade for now). InnoDB uses row-level locks, so it's extremely unlikely to cause such issues.
- erik_seaberg 3y agoInnoDB also supports transactions.