… Q: Doesn’t the primary key solution for random selection only work when the IDs for movies are …count the movies per production year for each kind_id. It was more efficient in this case to force MySQL…and columns. It turned out this solution was 150x faster for this case, so your suggestion is a …
Post: More on MySQL transaction descriptors optimization
… (and thus, faster inter-process/node communication…select avg(id) from sbtest$i force key (primary) select count(*) from sbtest$i WHERE k like ‘%0%’ SysBench-0.5/lua: POINT_SELECT…mysql-user=root –mysql-db=sbtest8t1M –mysql-table-engine=INNODB –mysql-socket=/tmp/mysql.sock –oltp-point-selects…
Post: Benchmarking Percona Server TokuDB vs InnoDB
…misleading? Obviously we can say that InnoDB is faster, but you should look into the steady …` is low selectivity is not good for fast inserts, but it is suitable for range selects by `id…lua –oltp-table-size=10000 –mysql-user=root –oltp-tables-count=32 –mysql_table_engine=tokudb –oltp_auto_inc=…
Post: The case for getting rid of duplicate “sets”
…easily process data in sets, which can be much faster than processing it serially. When the relational database was…set (0.00 sec) mysql> select count(*) from ex1; +———-+ | count(*) | +———-+ | 73027220 | +———-+ 1 row in set (0.00 sec) mysql> select sum(val) from ex1; +———–+ |…
Post: Flexviews - part 3 - improving query performance using materialized views
… incremental refresh method can be many orders of magnitude faster than the original query execution time. It may …quickly than COUNT(*). mysql> select count(*) cnt from order_lines\G *************************** 1. row *************************** cnt: 155187034 1 row in set (32.03 sec) mysql> select …
Post: Indexes in MySQL
…faster by 2 times. Consider more extremal case: selectivity ~95%: SELECT cnt2 / cnt1 FROM (SELECT count(*) cnt1 FROM t2) d1, (SELECT count…
Post: Why MySQL could be slow with large tables ?
…scan by index: mysql> select count(pad) from large; +————+ | count(pad) | +————+ | 31457280 | +————+ 1 row in set (4 min 58.63 sec) mysql> select count(pad) from … – For large data sets full table scans are often faster than range scans and other types of index lookups. …
Post: Shard-Query turbo charges Infobright community edition (ICE)
…carriers in the table: mysql> select count(*), count(distinct UniqueCarrier) from dim_flightG *************************** 1. row *************************** count(*): 58625 count(distinct UniqueCarrier): 29 1… glance You will notice that Shard-Query is faster in nearly every case. The performance of …
Post: UDF -vs- MySQL Stored Function
…minutes to 26 minutes. I knew using UDF would be faster, but I had no idea how much. Have you …7 million records: mysql> select count(*) from paintings where title != ltrim_junk(title); +———-+ | count(*) | +———-+ | 101533 | +———-+ 1 row in set (6.82 sec) mysql> select count(*) from …
Post: How expensive is a WHERE clause in MySQL?
… seconds. Next I ran it with a trivial WHERE clause: mysql> select count(*) from t where a = current_date; (Pop quiz: do I…% cost for the query. If I add another WHERE clause, mysql> select count(*) from t where a = current_date and left(a, 10… make your queries faster — you usually can’t optimize the WHERE clause itself, only the way that the MySQL optimizer chooses to…

