MySQL Forums :: Performance :: Wrong estimation of Rows in explain


Advanced Search

Re: Wrong estimation of Rows in explain
Posted by: Rick James ()
Date: August 02, 2016 06:23PM

Try innodb_buffer_pool_size = 2G -- if that leads to swapping, then it is too big.

EXPLAIN's row estimate is only approximate. There is no way to make it exact. It will even estimate the number of rows in the table.

For this:

a.col1 = b.col1 and a.col2 = b.col2

have both of these:

On a: INDEX(col1, col2)
On b: INDEX(col1, col2)

That is, a composite index is better (in this case) than an index on a single column.

Options: ReplyQuote


Subject Views Written By Posted
Wrong estimation of Rows in explain 511 Rathi Rao 07/27/2016 06:19AM
Re: Wrong estimation of Rows in explain 256 Peter Brawley 07/27/2016 08:55AM
Re: Wrong estimation of Rows in explain 283 Rathi Rao 07/27/2016 11:58PM
Re: Wrong estimation of Rows in explain 270 Peter Brawley 07/28/2016 09:14AM
Re: Wrong estimation of Rows in explain 271 Rathi Rao 07/29/2016 05:11AM
Re: Wrong estimation of Rows in explain 262 Peter Brawley 07/29/2016 01:10PM
Re: Wrong estimation of Rows in explain 266 Rick James 07/29/2016 06:58PM
Re: Wrong estimation of Rows in explain 250 Rathi Rao 08/02/2016 05:48AM
Re: Wrong estimation of Rows in explain 267 Rick James 08/02/2016 06:23PM
Re: Wrong estimation of Rows in explain 245 Rathi Rao 08/02/2016 05:38AM
Re: Wrong estimation of Rows in explain 272 james wang 08/04/2016 05:31AM


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.