QUERY PLAN
Sort (cost=65.19..65.20 rows=8 width=26)
Sort Key: id
-> Seq Scan on tbl_sales_contract_invoices (cost=0.00..65.06 rows=8 width=26)
Filter: (contract_id = ANY ('{1186,3108,3830,3842,3803,3854}'::integer[]))