Chapter 4 QUERYING AND MODIFYING DATA 223 TABLE
Chapter 4 QUERYING AND MODIFYING DATA 223 TABLE 4.8 continued MATHEMATICAL FUNCTIONS IN T-SQL Function Parameters Result LOG (Float expression) Natural logarithm of the specified expression. LOG10 (Float expression) Base 10 logarithm of the specified expression. PI ( ) Returns 3.1415926535897931. POWER (Numeric expression, y) Value of numeric expression to the power of y. RADIANS (Numeric expression) Radians converted from degrees of the numeric expression. RAND (seed ) Random float value between zero and one. ROUND (Numeric expression, Numeric expression rounded off to length) the precision (length) of a number. SIGN (Numeric expression) Returns the positive, negative, or zero sign of a numeric expression. SIN (Float expression) Trigonometric sine of the specified angle. SQRT (Float expression) Square root of the specified expression. TAN (Float expression) Tangent of the specified expression. SQUARE (Float expression) Square of the specified expression. The following example shows you a query that uses some of the many mathematical functions in SQL Server. Notice that when a query is non-data retrieval, as this one is, a FROM clause does not have to be specified. SELECT pi() AS PI , abs(-44) AS Absolute , power(2,3) AS Power Discussion of mathematical functions would be an involved endeavor for this medium. this blog does not set out to make mathematical geniuses out of every SQL developer. To become fully versed in all mathematical functions would require a significant education in the science of mathematics. Character functions interact against alphanumeric data in a similar fashion as numeric data interacts with mathematical functions.
If you looking for unlimited one inclusive web hosting plan please check unlimited web hosting website.