QUERY PLAN
Sort (cost=58.88..58.91 rows=12 width=26)
Sort Key: id
-> Seq Scan on tbl_sales_contract_invoices (cost=0.00..58.66 rows=12 width=26)
Filter: (contract_id = ANY ('{4497,4074,3325,3679,3705}'::integer[]))