May 25, 2012

Post: Trailing spaces in MySQL

… length used. Trailing spaces were removed in both cases. With MySQL 5.0 however things changed so now VARCHAR keeps trailing spaces while… invisible as those trailing spaces are removed upon retrieval. This is something you need to watch both upgrading to MySQL 5.0 as well as designing your applications – you should keep into account if you mind trailing spaces stored…

Post: Why audit logging with triggers in MySQL is bad for replication

… an audit table for changes to the Foo table. The trail is kept using two triggers on that table. select trigger…

Comment: Upgrading MySQL

… they are stored. Handling of trailing spaces is version-dependent. As of MySQL 5.0.3, trailing spaces are retained when values are stored and retrieved, in conformance with standard SQL. Before MySQL 5.0.3, trailing spaces…

Comment: Trailing spaces in MySQL

…| “a ” = “a” | +————+ | 1 | +————+ 1 row in set (0.00 sec) mysql> SELECT BINARY “a ” = BINARY “a”; +————————–+ | BINARY “a ” = BINARY “a” | +————————–+… practice would be to have the application strip trailing spaces before insertion. I can’t think of…

Post: To pack or not to pack - MyISAM Key compression

… be enough to understand performance implications of this approach. Note trailing spaces for strings are not stored in the index even… blocks need to be treated differently. For uncompressed index blocks MySQL can do binary search inside the page – kind of jumping…. For compressed block this is not going to work and MySQL will need to scan keyblock from the start uncompressing keys…

Comment: Making the impossible: 3 nodes intercontinental replication

To continue Harrison’s trail, it now depends on what you are comparing against whether … the answer is that you have a readonly datacenter with mysql slaves, and all writes are directed to one master data…

Comment: MySQL Installation and upgrade scripts.

…” did not trigger table repairs (bad, varchar string comparison with trailing spaces might return different from expected results), no problems with… present time I decided to upgrade to 5.0.36sp1 (MySQL Enperprise) it seems to be the most stable release, it…