56,940
社区成员




id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE p2fmd ref PRIMARY,products_id,fit_model,language_id fit_model 257 const 18 Using where
1 SIMPLE p2c ref PRIMARY,categories_id PRIMARY 4 article.p2fmd.products_id 65 Using index
1 SIMPLE c eq_ref PRIMARY,categories_status PRIMARY 4 article.p2c.categories_id 1 Using where
show index from p2fmd
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
products_to_fit_model_description 0 PRIMARY 1 fit_model_id A NULL NULL NULL BTREE
products_to_fit_model_description 0 PRIMARY 2 language_id A 1127672 NULL NULL BTREE
products_to_fit_model_description 1 products_id 1 products_id A 5125 NULL NULL BTREE
products_to_fit_model_description 1 fit_model 1 fit_model A 80548 NULL NULL BTREE
products_to_fit_model_description 1 language_id 1 language_id A 8 NULL NULL BTREE
show index from p2c
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
products_to_categories 0 PRIMARY 1 products_id A NULL NULL NULL BTREE
products_to_categories 0 PRIMARY 2 categories_id A 6507 NULL NULL BTREE
products_to_categories 1 categories_id 1 categories_id A 929 NULL NULL BTREE
show index from categories
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
categories 0 PRIMARY 1 categories_id A 925 NULL NULL BTREE
categories 1 idx_categories_parent_id 1 parent_id A 42 NULL NULL BTREE
categories 1 categories_status 1 categories_status A 1 NULL NULL BTREE
SELECT *
FROM products_to_fit_model_description p2fmd, categories c, products_to_categories p2c
WHERE p2fmd.products_id = p2c.products_id
AND p2c.categories_id = c.categories_id
AND c.categories_status =1
AND p2fmd.fit_model_id != '87098'
AND p2fmd.fit_model = 'nokia n78'
AND p2fmd.language_id = '3'
show index from p2fmd
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
products_to_fit_model_description 0 PRIMARY 1 fit_model_id A NULL NULL NULL BTREE
products_to_fit_model_description 0 PRIMARY 2 language_id A 1127672 NULL NULL BTREE
products_to_fit_model_description 1 products_id 1 products_id A 5125 NULL NULL BTREE
products_to_fit_model_description 1 fit_model 1 fit_model A 80548 NULL NULL BTREE
products_to_fit_model_description 1 language_id 1 language_id A 8 NULL NULL BTREE
show index from p2c
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
products_to_categories 0 PRIMARY 1 products_id A NULL NULL NULL BTREE
products_to_categories 0 PRIMARY 2 categories_id A 6507 NULL NULL BTREE
products_to_categories 1 categories_id 1 categories_id A 929 NULL NULL BTREE
show index from categories
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
categories 0 PRIMARY 1 categories_id A 925 NULL NULL BTREE
categories 1 idx_categories_parent_id 1 parent_id A 42 NULL NULL BTREE
categories 1 categories_status 1 categories_status A 1 NULL NULL BTREE