开发者

Usage of SET NOCOUNT ON [duplicate]

This question already has answers here: Closed 11 years ago.

Possible Duplicate:

SET NOCOUNT ON usage

Why do we use the below statement in Trigge开发者_开发知识库rs and stored procedures?

SET NOCOUNT ON

Could any one explain me please? I have gone through the similar question posted before. But as I am new learning SQL, I am unable to understand their discussion.


When SET NOCOUNT is ON, the count (indicating the number of rows affected by a Transact-SQL statement) is not returned. When SET NOCOUNT is OFF, the count is returned.

So if you do an UPDATE query (for example) the query will not return the affected rows.

for more information check out => http://msdn.microsoft.com/en-us/library/aa259204(v=sql.80).aspx

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜