While this is technically not an answer to your question, you could alternatively modify your SQL statement to simply return the newest row. In MSSQL syntax it looks something like this:
SELECT TOP 1 *
FROM Orders
INNER JOIN (
SELECT id, updated_at AS modified from Orders
UNION
SELECT id, created_at from Orders
) AS whatever ON whatever.id = Orders.id
ORDER BY whatever.modified DESC
This will always return whichever row was modified (as in created or updated) last, and takes no parameters.