QUERY PLAN
Sort (cost=64.09..64.11 rows=7 width=26)
Sort Key: id
-> Seq Scan on tbl_sales_contract_invoices (cost=0.00..63.99 rows=7 width=26)
Filter: (contract_id = ANY ('{4496,4497,4486,4491,4492,4324,4479}'::integer[]))