June 19, 2013

Post: MySQL Indexing Best Practices: Webinar Questions Followup

…), KEY K(id2)) engine=INNODB; when table has to be traversed in both directions for different queries. This will use fast primary key… too many? A: There is a hard limit on amount of indexes you can have, which is 64 per table in recent MySQL versions. However…. Also check out my old article on the topic which goes into a lot more details. Q: how mysql use index for group by? A: If…

Post: Using VIEW to reduce number of tables used

CHECK OPTION failed ‘test.post123′ This happens because as we do not pass user_id value to underlying table MySQLtables as blackhole and define a triggers on them to update base tables, which will make rows available in the views. As the storage engine

Post: MySQL 5.6.10 Optimizer Limitations: Index Condition Pushdown

MySQL 5.6.10. This turned into a really nice exercise for checkingmysql> SELECT * FROM cast_info WHERE role_id = 1 and note like ‘%Jaime%’; On a table like this: CREATE TABLEa query faster, which means you need more manual care and tuning now. MySQL is conservative about “Using

Post: ALTER TABLE: Creating Index by Sort and Buffer Pool Size

table which would look as following in terms of data and index size: mysql> show table status like “sbtest” \G *************************** 1. row *************************** Name: sbtest EngineCheckwhich builds table with primary key only when creating a table

Post: How to recover deleted rows from an InnoDB Tablespace

tables and indexes (with their IDs) to the error log. mysql (employees) > CREATE TABLE innodb_table_monitor (id int) ENGINE=InnoDB; TABLEmysql-data-recovery:generating_a_table_definition With the table definition on table

Post: InnoDB Full-text Search in MySQL 5.6: Part 2, The Queries!

a table, and configure that table to be our stopword list for InnoDB? This is the table that we’re trying to emulate: mysqltable, be prepared for a table rebuild. Calculation of match score is completely different between the two engines

Post: Percona XtraDB Cluster reference architecture with HaProxy

… able to use check MySQL via HTTP. The clustercheck script is a simple shell script, which accepts HTTP requests, and checks MySQL on …driver=mysqlmysql-engine-trx=yes –mysql-table-engine=innodb –mysql-host=127.0.0.1 –mysql-port=3307 –mysql-user=sbtest –mysql-password=sbpass –oltp-table-size…

Post: Using MyISAM in production

MySQL database directory. This way accesses to non-checked tables fail with tableengines. It is however also different. MyISAM has in-row fragmentation whichtables (you can throw them away if it server crashes). You can use multiple of cache tables to avoid concurrency issues. Temporary tables used

Post: Recovering Innodb table Corruption

table I am getting: mysql> check table test; ERROR 2013 (HY000): Lost connection to MySQL server during query mysql> check table test; +———–+——-+———-+———-+ | Table

Post: On Character Sets and Disappearing Tables

MySQL manual tells us that regardless of whether or not we use “SET FOREIGN_KEY_CHECKSENGINE=INNODB; trying to do something like “ALTER TABLE bar DROP j” or “ALTER TABLE…, which is also what we’d expect: table “foo” and table “bar”… suppose that this was actually a long-running ALTER statement. Maybe…