QUERY PLAN
Sort (cost=70.73..70.73 rows=1 width=215)
Sort Key: pt.id
-> Nested Loop Left Join (cost=0.44..70.72 rows=1 width=215)
-> Index Scan using tbl_term_taxonomy_relationships_object_id_term_id_idx on tbl_term_taxonomy_relationships pt (cost=0.29..62.50 rows=1 width=85)
Index Cond: ((object_id = ANY ('{6,5,4,3,2,1}'::integer[])) AND (term_id = 18))
Filter: (object_type = 11)
-> Index Scan using tbl_term_taxonomies_pkey on tbl_term_taxonomies tt (cost=0.15..8.17 rows=1 width=97)
Index Cond: (pt.taxonomy_id = id)