Compound Operators
SQL Server 2008 introduces the Compound Operators as a programmability enhancement in Transact-SQL. Compound operators execute some operation, such as +, -, * and /, and set an original value to the result of the operation. It is just a simpler syntax that you can use on commonly performed operation such as incrementing a variable by a certain number.
As an example, instead of doing the following:
SET @Index = @Index + 1
it can now simplified as follows:
SET @Index += 1
No comments:
Post a Comment