QUERY PLAN
Sort (cost=139.82..139.83 rows=1 width=203)
Sort Key: serial_no DESC
-> Seq Scan on tbl_sales_contracts (cost=0.00..139.81 rows=1 width=203)
Filter: ((created_at >= '2026-06-02 00:00:00+08'::timestamp with time zone) AND (created_at <= '2026-06-02 23:59:59+08'::timestamp with time zone) AND ((serial_no)::text ~~* '%2026-06-02-%'::text) AND (length((serial_no)::text) = 14))