Remix.run Logo
sgarland 7 hours ago

If you include an ORDER BY, the DB _may_ continue searching. MySQL (and, I assume, MS SQL Server, since it also can cluster the PK) can stop early in some circumstances.

But if you just have a LIMIT, then no - any RDBMS should stop as soon as it’s reached your requested limit.

dotancohen 6 hours ago | parent [-]

Right, that's why I add it.