Showing entries 12621 to 12630 of 44114
« 10 Newer Entries | 10 Older Entries »
Range access: now in an IN predicate near you.

Several users have reported that certain queries with IN predicates can't use index scans even though all the columns in the query are indexed. What's worse, if you reformulate your query without IN, the indexes are used. Let's take some example query. Suppose we have a table with two indexed columns:

CREATE TABLE t1 ( 
  col1 INTEGER,
  col2 INTEGER,
  ...
  KEY key1( col1, col2 ) );
Let's take a look at some queries that could take advantage of the key1 index to read rows without accessing the table.

  1. SELECT col1, col2 FROM t1 WHERE col1 = 100;
  2. SELECT col1, col2 FROM t1 WHERE col1 > 100 AND col1 < 200;
  3. SELECT col1, col2 FROM t1 WHERE col1 > 100 AND col1 < 200 OR col1 > 300 AND col1 < 400;
  4. SELECT col1, col2 FROM t1 WHERE col1 = 100 AND col2 > 100 AND cold2 < 200;


[Read more]
Online Schema Upgrade in MySQL Galera Cluster using TOI Method

December 10, 2013 By Severalnines

As a follow-up to the Webinar on Zero Downtime Schema Changes in Galera Cluster, we’ll now walk you through the detailed steps on how to update your schema. The two methods (TOI and RSU) have both their pros and cons, and given parameters like table size, indexes, key_buffer_size, disk speed, etc., it is possible to estimate the time taken for the schema to be upgraded. Also, please note that a schema change is non-transactional so it would not be possible to rollback the DDL if it fails midway. Therefore, it is always recommended to test the schema changes and ensure you have recoverable backups before performing this on your production clusters. 

This post examines the way DDL changes are propagated in Galera, and outlines the steps to upgrade the …

[Read more]
Testing the UNION ALL Optimization in MySQL 5.7 DMR3

When MySQL 5.7 DMR3 was released, I couldn’t wait to try out the new UNION ALL optimization that no longer requires data to be materialized in a temporary table.

This new optimization can be seen via EXPLAIN, but it is also nice to run it through SHOW PROFILES, which breaks down query execution step by step. However, this feature is now deprecated (since it overlaps with performance_schema), and will be removed in a future version.

So today I wanted to show you a combination of: * What a UNION ALL statement looks like in MySQL 5.6 (EXPLAIN, SHOW PROFILES). * How it is improved in MySQL 5.7 (EXPLAIN, SHOW PROFILES). * How you can easily emulate the SHOW PROFILES feature with performance_schema + ps_helper

[Read more]
Testing the UNION ALL Optimization in MySQL 5.7 DMR3

When MySQL 5.7 DMR3 was released, I couldn’t wait to try out the new UNION ALL optimization that no longer requires data to be materialized in a temporary table.

This new optimization can be seen via EXPLAIN, but it is also nice to run it through SHOW PROFILES, which breaks down query execution step by step. However, this feature is now deprecated (since it overlaps with performance_schema), and will be removed in a future version.

So today I wanted to show you a combination of:

  • What a UNION ALL statement looks like in MySQL 5.6 (EXPLAIN, SHOW PROFILES).
  • How it is improved in MySQL 5.7 (EXPLAIN, SHOW PROFILES).
  • How you can easily emulate the SHOW PROFILES feature with performance_schema + …
[Read more]
#DBHangOps 12/11/13 -- Backups, Sharding, and more!

#DBHangOps 12/11/13 -- Backups, Sharding, and more!

Check out the recording below!

Happy Holidays!

Participate in #DBHangOps this Wednesday, December, 11, 2013 at 12:00pm pacific (19:00 GMT), to discuss:

  • Backups

    • How do you do them? How often?
    • How do you test your backups?
    • What backup tools would you suggest?
  • Sharding

    • How do you deal with sharded database architectures?
    • What tools do you use for managing a sharded environment?
  • How do you configure your application to talk to MySQL?

    • Do you use VIPs, DNS CNAMEs, hard-coded strings in a config file, or something else?
  • Load Balancers and MySQL …

[Read more]
Presents for DBAs

Dear Fellow DBAs–You are a pain to shop for at holiday time. Once again @stoker has compiled a list that you can print out, circle what you desire, and hand to a relative. If you do not want a Duck Dynasty Chia Pet or a blanket with arms, print this now NOW!

Presents for your MySQL DBA Cafe Press yet again has a large line of DBA themed t-shirts. This shirt is available in Women’s, Maternity, and seven other styles at Zazzle has its own page of DBA shirts

[Read more]
Old and new MySQL verbosity

I was pleased to see Morgan’s announcement about a fix to an old problem of mine. In March 2012 I complained about MySQL verbosity during installation.

In MySQL 5.7.3, this behavior was changed. While the default is still as loud as it can, you can now add an option (log_error_verbosity) to send only errors to STDERR, which allows you to hide the output of mysql_install_db, and still get the errors, if they occur.

Well done!

However, the same obnoxious verbosity is also in MariaDB 10.0.x. Since I discussed this specific bug with a few MariaDB developers early in 2012, I was disappointed to see this same output when running mysql_install_db with MariaDB. Here’s the same appeal: MariaDB …

[Read more]
MySQL Repo News

What’s new in the MySQL Yum repositories A little over a month ago we launched the official MySQL Yum repository. An official repo was a long standing request from the community, and we’ve had it on our list of todos for a long time. We finally got it done, and in the process we modernized […]

Live from the world of MySQL RE

Welcome to the official MySQL Release Engineering blog!

The MySQL error log in MySQL 5.7

The MySQL error log has received some attention in MySQL 5.7, with a new setting called log_error_verbosity.

There are three possible values, as documented in the manual:

Verbosity Value Message Types Logged
1 Errors only
2 Errors and warnings
3 Errors, warnings, and notes (default)

As Giuseppe has written about previously, writing notes or “informational events” can create debugging problems because they reduce the …

[Read more]
Showing entries 12621 to 12630 of 44114
« 10 Newer Entries | 10 Older Entries »