MySQL Forums
Forum List  »  Performance

Re: Very slow query when too many joins
Posted by: Rick James
Date: June 05, 2016 05:36PM

Here's my rant against EAV: http://mysql.rjweb.org/doc.php/eav

You do need a composite index on (ads_id, field_id). In particular it would be better to have
* ENGINE=InnoDB -- so that the PK is clustered
* PRIMARY KEY(ads_id, field_id)

In my.cnf :
optimizer_search_depth = 1

Options: ReplyQuote


Subject
Views
Written By
Posted
4677
June 05, 2016 09:17AM
1767
June 05, 2016 09:27AM
1389
June 05, 2016 10:48AM
1444
June 05, 2016 03:33PM
Re: Very slow query when too many joins
1290
June 05, 2016 05:36PM
1219
June 06, 2016 02:23AM
1180
June 06, 2016 03:33AM
1045
June 06, 2016 08:36AM
1242
June 06, 2016 09:02AM
1124
June 06, 2016 11:30AM
1151
June 06, 2016 02:11PM


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.