Problem Statement
Which rewrite makes a non-SARGable filter SARGable for date equality?
Explanation
Wrapping the column in a function blocks index seeks. Range boundaries allow the engine to use the index on created_at efficiently.
This pattern also avoids time zone surprises and keeps the predicate precise and fast.
Code Solution
SolutionRead Only
created_at >= :d AND created_at < :d + INTERVAL '1 day'
