SQL SERVER – Introduction to Function SIGN
- by pinaldave
Yesterday I received an email from a friend asking how do SIGN function works. Well SIGN Function is very fundamental function. It will return the value 1, -1 or 0. If your value is negative it will return you negative -1 and if it is positive it will return you positive +1. Let us start with a simple small example.
DECLARE @IntVal1 INT, @IntVal2…