QUERY PLAN
Sort (cost=73.92..73.96 rows=14 width=26)
Sort Key: id
-> Seq Scan on tbl_sales_contract_invoices (cost=0.00..73.66 rows=14 width=26)
Filter: (contract_id = ANY ('{3835,3830,3822,3816,3812,3811,3770,3809,3805,3803}'::integer[]))