MySQL Forums
Forum List  »  Performance

Re: Server just hanging (Copying to tmp table)
Posted by: Thomas Deliduka
Date: December 15, 2005 11:27AM

Your Query change:
*************************** 1. row ***************************
id: 1
select_type: SIMPLE
table: xno_items
type: ref
possible_keys: active
key: active
key_len: 4
ref: const
rows: 1647
Extra: Using temporary; Using filesort
*************************** 2. row ***************************
id: 1
select_type: SIMPLE
table: xno_prod_index
type: eq_ref
possible_keys: PRIMARY
key: PRIMARY
key_len: 64
ref: finerkitchens_com.xno_items.itemid,const
rows: 1
Extra:
*************************** 3. row ***************************
id: 1
select_type: SIMPLE
table: xno_item_cat
type: index
possible_keys: NULL
key: PRIMARY
key_len: 8
ref: NULL
rows: 5155
Extra: Using index
*************************** 4. row ***************************
id: 1
select_type: SIMPLE
table: xno_categories
type: eq_ref
possible_keys: PRIMARY,active
key: PRIMARY
key_len: 4
ref: finerkitchens_com.xno_item_cat.catid
rows: 1
Extra:
*************************** 5. row ***************************
id: 1
select_type: SIMPLE
table: xno_manufacturers
type: eq_ref
possible_keys: PRIMARY
key: PRIMARY
key_len: 4
ref: finerkitchens_com.xno_items.mfgid
rows: 1
Extra:

Original Query:
*************************** 1. row ***************************
id: 1
select_type: SIMPLE
table: xno_items
type: ref
possible_keys: PRIMARY,active
key: active
key_len: 4
ref: const
rows: 1647
Extra: Using temporary; Using filesort
*************************** 2. row ***************************
id: 1
select_type: SIMPLE
table: xno_prod_index
type: eq_ref
possible_keys: PRIMARY
key: PRIMARY
key_len: 64
ref: finerkitchens_com.xno_items.itemid,const
rows: 1
Extra: Using where
*************************** 3. row ***************************
id: 1
select_type: SIMPLE
table: xno_item_cat
type: index
possible_keys: NULL
key: PRIMARY
key_len: 8
ref: NULL
rows: 5155
Extra: Using index
*************************** 4. row ***************************
id: 1
select_type: SIMPLE
table: xno_categories
type: eq_ref
possible_keys: PRIMARY,active
key: PRIMARY
key_len: 4
ref: finerkitchens_com.xno_item_cat.catid
rows: 1
Extra: Using where
*************************** 5. row ***************************
id: 1
select_type: SIMPLE
table: xno_manufacturers
type: eq_ref
possible_keys: PRIMARY
key: PRIMARY
key_len: 4
ref: finerkitchens_com.xno_items.mfgid
rows: 1
Extra:


Incidentally, I tried putting the xno_prod_index.word ='thermometer' in the "where" clause and left the xno_categories.active = 1 up in the join and then disabled a category and ran the query. The Items in the disabled category still showed up. When I used my original query, they did not. It is as if the MySQL SErver is ignoring the additional filters on the join statement.

I know enough to be dangerous. Thanks for being patient!

Options: ReplyQuote


Subject
Views
Written By
Posted
8259
December 07, 2006 10:30AM
9633
September 23, 2005 01:56AM
4896
October 05, 2005 04:58AM
6095
October 05, 2005 11:49PM
5373
October 06, 2005 01:34AM
6677
October 06, 2005 04:57PM
Re: Server just hanging (Copying to tmp table)
4165
December 15, 2005 11:27AM
6500
January 21, 2008 10:14AM
5843
January 21, 2008 10:53AM
5305
May 19, 2008 09:41AM
5516
February 05, 2008 10:27AM
6061
March 12, 2008 08:37AM
6117
November 14, 2008 12: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.