Advertisement
Guest User

Untitled

a guest
Dec 9th, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.11 KB | None | 0 0
  1. # Time: 2018-12-03T05:02:26.243369Z
  2. # User@Host: dbname[dbname] @ localhost [] Id: 13187589
  3. # Query_time: 24.966048 Lock_time: 0.000866 Rows_sent: 10 Rows_examined: 3013851
  4. use dbname;
  5. SET timestamp=1543813346;
  6. SELECT^M
  7. ^M
  8. wp_posts.post_title as title,^M
  9. wp_posts.ID as id,^M
  10. wp_posts.post_date as date,^M
  11. wp_posts.post_content as content,^M
  12. '' as excerpt,^M
  13. 'pagepost' as content_type,^M
  14. (SELECT^M
  15. wp_users.display_name as author^M
  16. FROM wp_users^M
  17. WHERE wp_users.ID = wp_posts.post_author^M
  18. ) as author,^M
  19. '' as ttid,^M
  20. wp_posts.post_type as post_type,^M
  21. ((case when^M
  22. (wp_posts.post_title LIKE 'random value over here')^M
  23. then 20 else 0 end) + (case when^M
  24. (wp_posts.post_title LIKE 'another random value over here')^M
  25. then 10 else 0 end) + (case when^M
  26. (wp_posts.post_title LIKE 'random random random')^M
  27. then 10 else 0 end) + (case when^M
  28. (wp_terms.name = 'the best random value you can ever see')^M
  29. then 10 else 0 end)) as relevance^M
  30. FROM wp_posts^M
  31. LEFT JOIN wp_postmeta ON wp_postmeta.post_id = wp_posts.ID^M
  32. ^M
  33. LEFT JOIN wp_term_relationships ON wp_posts.ID = wp_term_relationships.object_id^M
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement