Advertisement
Guest User

Untitled

a guest
Jan 2nd, 2012
1,152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.88 KB | None | 0 0
  1. db=# explain analyze SELECT "Threads"."Id" FROM "Threads" WHERE "Threads"."BoardId" = 33 ORDER BY "Threads"."IsAnnouncement" DESC, "Threads"."LastPostId" DESC LIMIT 40 OFFSET 0;
  2. QUERY PLAN
  3.  
  4. ------------------------------------------------------------------------------------------------------------------------------
  5. Limit (cost=18861.88..18861.98 rows=40 width=10) (actual time=160.508..160.516 rows=40 loops=1)
  6. -> Sort (cost=18861.88..19058.48 rows=78641 width=10) (actual time=160.504..160.507 rows=40 loops=1)
  7. Sort Key: "IsAnnouncement", "LastPostId"
  8. Sort Method: top-N heapsort Memory: 18kB
  9. -> Seq Scan on "Threads" (cost=0.00..16376.06 rows=78641 width=10) (actual time=0.014..132.901 rows=78889 loops=1)
  10. Filter: ("BoardId" = 33)
  11. Total runtime: 160.562 ms
  12. (7 rows)
  13.  
  14.  
  15. db=#
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement