QUERY PLAN
Sort (cost=136.97..137.01 rows=19 width=227)
Sort Key: id DESC
-> Seq Scan on tbl_erp_collect_tickets (cost=0.00..136.56 rows=19 width=227)
Filter: ((status = 2) AND (sales_contract_id = ANY ('{1186,529,786,1558,26,1692,1697,655,616,656,1091,653,798,1177,522}'::integer[])))