Uncategorized

ROWCOUNT

Setting the SET ROWCOUNT option causes most Transact-SQL statements to stop processing when they have been affected by the specified number of rows. This includes triggers. SET ROWCOUNT 5 SELECT ROW_NUMBER() OVER (ORDER BY (SELECT NULL)) N FROM ( VALUES(0),(0),(0),(0),(0),(0),(0),(0),(0),(0) ) a (n) GO — (5 rows affected) SET ROWCOUNT…

Read more