Re: how to optimise query for 10+ millions records
Posted by:
Rick James
Date: February 11, 2012 11:26PM
Need some details; please provide
* SHOW CREATE TABLE tbl\G -- engine, indexes
* SHOW TABLE STATUS LIKE 'tbl'\G -- sizes
* EXPLAIN SELECT ...\G -- clues of inefficiencies
* SHOW VARIABLES LIKE '%buffer%'; -- cache size
and surround them with [ code ] and [ / code ]
How much RAM do you have?
We will probably focus on the LIKE. Some things to note:
* If @l_Destination begins with a wildcard (% or _), the index will be useless.
* Taking a function (in your case: "IFNULL(...)") of a column makes it impossible to use an index on that column.
Subject
Views
Written By
Posted
2768
February 09, 2012 03:30AM
1645
February 09, 2012 05:31AM
1326
February 09, 2012 05:38AM
1196
February 09, 2012 05:58PM
Re: how to optimise query for 10+ millions records
1188
February 11, 2012 11:26PM
1458
February 12, 2012 10:12PM
1311
February 13, 2012 02:18PM
1476
February 14, 2012 02:33AM
1249
February 14, 2012 07:24AM
1335
February 15, 2012 07:30AM
1742
February 16, 2012 03:54AM
1229
February 17, 2012 01:20AM
1125
February 17, 2012 03:57PM
1442
February 17, 2012 05:12PM
1268
February 18, 2012 07:18AM
1280
February 21, 2012 03:25AM
1305
February 24, 2012 10:45AM
1241
February 20, 2012 02:21AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.