QUERY PLAN
Sort (cost=82.70..82.75 rows=20 width=26)
Sort Key: id
-> Seq Scan on tbl_sales_contract_invoices (cost=0.00..82.27 rows=20 width=26)
Filter: (contract_id = ANY ('{4055,3763,3755,3746,3803,3857,3935,3916,3900,3967,3978,3997,4098,4088,4091,4094,4095,4100,4101}'::integer[]))