sfmc // SQLPRODUCTION

TOP + ORDER BY for a Limited Ordered Set

Select a limited number of rows using SQL Server-style TOP syntax.

sqltoporder byt-sql
Context Pack →Open Workspace →
Trust & provenancePRODUCTION
Evidence tierPRODUCTIONOfficial sources1Other sources0Last verified2026-10-05

Evidence tier describes my hands-on relationship with the content. Official sources describe platform contracts/documentation. Production observations should not automatically be treated as official limits.

EvidencePRODUCTION
Difficultyfoundation
Verified2026-10-05
Use when

You need the newest N rows or a bounded sample.

SELECT TOP 100
    SubscriberKey,
    ModifiedDate
FROM [Source_DE]
ORDER BY ModifiedDate DESC
Why it works

SFMC Query Activities use SQL Server-style syntax rather than MySQL LIMIT.

Operational notes

The target Data Extension itself is not an ordered storage structure; use ORDER BY to choose rows, not as a downstream sorting guarantee.

Sources / verification