Skip to content

Instantly share code, notes, and snippets.

Last active December 18, 2015 00:28
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
explain analyze result
"Nested Loop Left Join (cost=13.23..11398.05 rows=523 width=29) (actual time=2.111..32.453 rows=3648 loops=1)"
" -> Nested Loop (cost=13.23..7297.25 rows=523 width=12) (actual time=2.101..21.872 rows=3648 loops=1)"
" -> Index Only Scan using albums_pkey on albums (cost=0.00..8.27 rows=1 width=4) (actual time=0.048..0.049 rows=1 loops=1)"
" Index Cond: (id = 1060)"
" Heap Fetches: 1"
" -> Nested Loop (cost=13.23..7283.75 rows=523 width=12) (actual time=2.045..21.312 rows=3648 loops=1)"
" -> Bitmap Heap Scan on album_photos (cost=13.23..2190.20 rows=611 width=8) (actual time=2.019..4.724 rows=3924 loops=1)"
" Recheck Cond: (album_id = 1060)"
" -> Bitmap Index Scan on index_album_photos_on_album_id_and_photo_id (cost=0.00..13.08 rows=611 width=0) (actual time=1.923..1.923 rows=3924 loops=1)"
" Index Cond: (album_id = 1060)"
" -> Index Scan using photos_pkey on photos (cost=0.00..8.33 rows=1 width=8) (actual time=0.004..0.004 rows=1 loops=3924)"
" Index Cond: (id = album_photos.photo_id)"
" Filter: (dead IS NOT TRUE)"
" Rows Removed by Filter: 0"
" -> Index Scan using connected_users_pkey on connected_users (cost=0.00..7.83 rows=1 width=25) (actual time=0.002..0.002 rows=1 loops=3648)"
" Index Cond: (photos.connected_user_id = id)"
"Total runtime: 32.927 ms"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment