QUERY PLAN
Sort (cost=145.25..145.30 rows=21 width=227)
Sort Key: id DESC
-> Seq Scan on tbl_erp_collect_tickets (cost=0.00..144.79 rows=21 width=227)
Filter: ((status = 2) AND (sales_contract_id = ANY ('{4248,1756,4324,4323,4144,3363,3388,3746,3997,3967,3900,1692,1697,1734,1091,1177,1702,4467}'::integer[])))