June 19, 2013

Post: Shard-Query EC2 images available

query/run_worker to contain the following: #!/bin/bash while [ 1 ] do ./worker >> /dev/null 2>&1 < /dev/null done; Where to findindexes (not even primary keys). Here is the complete InnoDB schema from one shard. The schema is duplicated

Comment: Duplicate indexes and redundant indexes

to drop duplicate index with same name. === Error === alter table emp drop index fk_deptid;ERROR 1553 (HY000): Cannot drop index ‘fk_deptid’: needed in a

Post: ANALYZE: MyISAM vs Innodb

table tool a little bit of time to run (even for this very small table) this is because ANALYZE does index scans to find

Post: ORDER BY ... LIMIT Performance Optimization

table may be scanned to find 10 rows. So index on (category_id, date_created) will be better idea. Lets take a look at aindex can be used to satisfy order by, index however will not be helpful to check c=5 (unless it is index covered query). Index on (c,a

Post: Finding out largest tables on MySQL Server

Finding largest tables on MySQL instance is no brainier in MySQL 5.0+ thanks to Information Schema but I still wanted to post little query I… of indexes. Large index size compared to data size often indicates there is a lot of indexes (so it is well possible there are some duplicates

Post: Sphinx: Going Beyond full text search

to mention general load on server such batch processing would put. The first alternative to this approach was to store duplicate data storing link toto retrieve all posts from given web site or forum from the global sphinx index. So in general we find

Comment: Find and remove duplicate indexes

on the “Duplicate keys on clustered index” section: Consider a chat room app, we have the messages table… performance of the following query. (Confirmed on MySQL 5.1 and …a room, you could stop scanning index just reading 100 entries, otherwise you’d have to read the entire index of (room_id) to find

Comment: INSERT ON DUPLICATE KEY UPDATE and REPLACE INTO

a trigger on an innodb table that “dumps” any updates to the table to a myisam table holding a log of updates. The update tableON DUPLICATE KEY UPDATE to achieve that. The problem is that I find many locked queries in the db as soon as there’s a