QUERY PLAN
Sort (cost=30.73..30.74 rows=5 width=29)
Sort Key: id
-> Bitmap Heap Scan on tbl_sales_contract_invoices (cost=17.44..30.67 rows=5 width=29)
Recheck Cond: (contract_id = ANY ('{4491,4483,4289,2818,2358}'::integer[]))
-> Bitmap Index Scan on tbl_sales_contract_invoices_contract_id_idx (cost=0.00..17.44 rows=5 width=0)
Index Cond: (contract_id = ANY ('{4491,4483,4289,2818,2358}'::integer[]))