QUERY PLAN
Sort (cost=150.80..150.85 rows=23 width=227)
Sort Key: id DESC
-> Seq Scan on tbl_erp_collect_tickets (cost=0.00..150.27 rows=23 width=227)
Filter: ((status = 2) AND (sales_contract_id = ANY ('{4486,4349,4417,4422,4430,4364,4426,4386,4332,4357,4334,4335,4377,4360,4327,4366,4385,4394,4414,4388}'::integer[])))