QUERY PLAN
Sort (cost=10.78..10.79 rows=1 width=257)
Sort Key: serial_no DESC
-> Seq Scan on tbl_erp_purchase_inbounds (cost=0.00..10.77 rows=1 width=257)
Filter: ((created_at >= '2026-06-09 00:00:00+08'::timestamp with time zone) AND (created_at <= '2026-06-09 23:59:59+08'::timestamp with time zone) AND ((serial_no)::text ~~* '%CGRKD-20260609-%'::text) AND (length((serial_no)::text) = 20))