This example limits SELECT result to 100 rows.
SELECT
SELECT TOP 100 * FROM table_name;
It is also possible to use a variable to specify the number of rows:
DECLARE @CountDesiredRows int = 100; SELECT TOP (@CountDesiredRows) * FROM table_name;