MySQL Forums
Forum List  »  Performance

Re: Monitoring large resultsets
Posted by: Aftab Khan
Date: July 12, 2012 08:13AM

Rick,

>One technique for improving things is to "vertically partition" a wide table (like jos_content) -- Meta data in one table (narrow, well indexed); bulky data in another table (with just an id). Then do a JOIN where one 'table' is a subquery finding the ids that are desired.

How would you justify what you suggested i.e. 'vertically partition'? if we look at provided EXPLAIN output, the query is doing tight index scan (no temporary table). There should be no need to touch the MEDIUMTEXT/TEXT fields for this query, so they should not impact performance any. It shouldn't need to touch anything except the index on (idx_state):



+----+-------------+-------------+-------+---------------------------------+-----------+---------+------+-------+-------------+ 
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra | 
+----+-------------+-------------+-------+---------------------------------+-----------+---------+------+-------+-------------+ 
| 1 | SIMPLE | jos_content | range | idx_section,idx_state,idx_catid | idx_state | 1 | NULL | 38791 | Using where | 
| 1 | SIMPLE | sm | ALL | idx_secid,idx_secshowarchive | NULL | NULL | NULL | 10 | Using where | 
| 1 | SIMPLE | cm | ALL | idx_catid,idx_catshowarchive | NULL | NULL | NULL | 81 | Using where | 
+----+-------------+-------------+-------+---------------------------------+-----------+---------+------+-------+-------------+ 
3 rows in set, 1 warning (0.02 sec)



Edited 1 time(s). Last edit at 07/12/2012 08:14AM by Aftab Khan.

Options: ReplyQuote


Subject
Views
Written By
Posted
2046
July 10, 2012 10:26PM
1114
July 11, 2012 02:01AM
896
July 12, 2012 02:19AM
946
July 12, 2012 03:37AM
940
July 12, 2012 04:13AM
982
July 12, 2012 05:49AM
1113
July 12, 2012 07:02AM
933
July 13, 2012 07:50PM
918
July 14, 2012 02:43AM
Re: Monitoring large resultsets
900
July 12, 2012 08:13AM
897
July 12, 2012 08:55AM
981
July 12, 2012 12:12PM


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.