QUERY PLAN
Sort (cost=142.45..142.50 rows=19 width=227)
Sort Key: id DESC
-> Seq Scan on tbl_erp_collect_tickets (cost=0.00..142.05 rows=19 width=227)
Filter: ((status = 2) AND (sales_contract_id = ANY ('{4422,4278,4246,3337,3404,3472,3465,3580,3602,3646,3670,3677,3749,3811,3809,3833,3841}'::integer[])))