doblej

Untitled

Mar 9th, 2022
34
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.31 KB | None | 0 0
  1. # Time: 220309 15:31:06
  2. # User@Host: hGjw9hSs[hGjw9hSs] @ localhost []
  3. # Thread_id: 14 Schema: xxxmadrid_com QC_hit: No
  4. # Query_time: 75.992033 Lock_time: 0.000453 Rows_sent: 0 Rows_examined: 2236296
  5. # Rows_affected: 4 Bytes_sent: 50
  6. # Tmp_tables: 3 Tmp_disk_tables: 0 Tmp_table_sizes: 507952
  7. # Full_scan: Yes Full_join: Yes Tmp_table: Yes Tmp_table_on_disk: No
  8. # Filesort: No Filesort_on_disk: No Merge_passes: 0 Priority_queue: No
  9. #
  10. # explain: id select_type table type possible_keys key key_len ref rows r_rows filtered r_filtered Extra
  11. # explain: 1 PRIMARY post ref PRIMARY,type_status_date type_status_date 82 const 1752 1752.00 100.00 100.00 Using where; Using index; Using temporary
  12. # explain: 1 PRIMARY meta__sku ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.30 1.09 Using where
  13. # explain: 1 PRIMARY meta__regular_price ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.42 0.10 Using where
  14. # explain: 1 PRIMARY meta__sale_price ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.06 0.03 Using where
  15. # explain: 1 PRIMARY meta__stock ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.30 1.10 Using where
  16. # explain: 1 PRIMARY meta__stock_status ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.56 1.10 Using where
  17. # explain: 1 PRIMARY meta__tax_class ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.55 1.10 Using where
  18. # explain: 1 PRIMARY meta__tax_status ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.58 1.10 Using where
  19. # explain: 1 PRIMARY meta__manage_stock ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.56 1.10 Using where
  20. # explain: 1 PRIMARY meta__thumbnail_id ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.55 1.03 Using where
  21. # explain: 1 PRIMARY variation_description ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.41 0.00 Using where
  22. # explain: 1 PRIMARY meta__length ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.03 0.10 Using where
  23. # explain: 1 PRIMARY meta__width ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.03 0.10 Using where
  24. # explain: 1 PRIMARY meta__height ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.03 0.10 Using where
  25. # explain: 1 PRIMARY meta__weight ref post_id,meta_key post_id 8 xxxmadrid_com.post.ID 25 91.10 0.03 0.10 Using where
  26. # explain: 1 PRIMARY parent ALL PRIMARY NULL NULL NULL 76077 74839.00 100.00 0.00 Using where; Using join buffer (flat, BNL join)
  27. # explain: 2 MATERIALIZED pwbe_variations ALL NULL NULL NULL NULL 1 0.00 100.00 100.00
  28. #
  29. SET timestamp=1646836266;
  30. INSERT INTO pwbe_products
  31. SELECT
  32. DISTINCT
  33. post.ID AS post_id
  34. FROM
  35. wp_posts AS post
  36. JOIN
  37. wp_posts AS parent ON (parent.ID = post.ID)
  38.  
  39. LEFT JOIN
  40. wp_postmeta AS meta__sku ON (meta__sku.post_id = post.ID AND meta__sku.meta_key = '_sku')
  41. LEFT JOIN
  42. wp_postmeta AS meta__regular_price ON (meta__regular_price.post_id = post.ID AND meta__regular_price.meta_key = '_regular_price')
  43. LEFT JOIN
  44. wp_postmeta AS meta__sale_price ON (meta__sale_price.post_id = post.ID AND meta__sale_price.meta_key = '_sale_price')
  45. LEFT JOIN
  46. wp_postmeta AS meta__stock ON (meta__stock.post_id = post.ID AND meta__stock.meta_key = '_stock')
  47. LEFT JOIN
  48. wp_postmeta AS meta__stock_status ON (meta__stock_status.post_id = post.ID AND meta__stock_status.meta_key = '_stock_status')
  49. LEFT JOIN
  50. wp_postmeta AS meta__tax_class ON (meta__tax_class.post_id = post.ID AND meta__tax_class.meta_key = '_tax_class')
  51. LEFT JOIN
  52. wp_postmeta AS meta__tax_status ON (meta__tax_status.post_id = post.ID AND meta__tax_status.meta_key = '_tax_status')
  53. LEFT JOIN
  54. wp_postmeta AS meta__manage_stock ON (meta__manage_stock.post_id = post.ID AND meta__manage_stock.meta_key = '_manage_stock')
  55. LEFT JOIN
  56. wp_postmeta AS meta__thumbnail_id ON (meta__thumbnail_id.post_id = post.ID AND meta__thumbnail_id.meta_key = '_thumbnail_id')
  57. LEFT JOIN
  58. wp_postmeta AS variation_description ON (variation_description.post_id = post.ID AND variation_description.meta_key = '_variation_description')
  59. LEFT JOIN
  60. wp_postmeta AS meta__length ON (meta__length.post_id = post.ID AND meta__length.meta_key = '_length')
  61. LEFT JOIN
  62. wp_postmeta AS meta__width ON (meta__width.post_id = post.ID AND meta__width.meta_key = '_width')
  63. LEFT JOIN
  64. wp_postmeta AS meta__height ON (meta__height.post_id = post.ID AND meta__height.meta_key = '_height')
  65. LEFT JOIN
  66. wp_postmeta AS meta__weight ON (meta__weight.post_id = post.ID AND meta__weight.meta_key = '_weight')
  67. -- featured_placeholder
  68.  
  69. WHERE
  70. post.post_type = 'product'
  71. AND (
  72. ((parent.post_title LIKE '%mascarillas%') )
  73. OR post.ID IN (SELECT parent_post_id FROM pwbe_variations)
  74. );
  75.  
Advertisement
Add Comment
Please, Sign In to add comment