ABS: - It returns the absolute value of n.
Syntax:: - ABS ( n )
Example: - The following example returns the absolute value of -15:
SELECT ABS(-15) "Absolute" FROM DUAL;
Absolute
----------
15
ACOS: - It returns the arc cosine of n. The argument nmust be in the range of -1 to 1, and the function returns values in the range of 0 to p, expressed in radians.
Syntax: - ACOS ( n )
Example: - The following example returns the arc cosine of .3:
SELECT ACOS(.3) "Arc_Cosine" FROM DUAL;
Arc_Cosine
----------
1.26610367
ASIN: - It returns the arc sine of n. The argument n must be in the range of -1 to 1, and the function returns values in the range of -p/2 to p/2 and are expressed in radians.
Syntax: - ASIN ( n )
Example: - The following example returns the arc sine of .3:
SELECT ASIN(.3) "Arc_Sine" FROM DUAL;
Arc_Sine
---------- .
304692654
ATAN: - It returns the arc tangent of n. The argument n can be in an unbounded range, and the function returns values in the range of -p/2 to p/2 and are expressed in radians.
Syntax: - ATAN ( n )
Example: - The following example returns the arc tangent of .3:
SELECT ATAN(.3) "Arc_Tangent" FROM DUAL;
Arc_Tangent
---------- .
291456794
CEIL: - It returns smallest integer greater than or equal to n.
Syntax: - CEIL ( n )
Example: - The following example returns the smallest integer greater than or equal to 15.7:
SELECT CEIL(15.7) "Ceiling" FROM DUAL;
Ceiling
----------
16
COS: - It returns the cosine of n (an angle expressed in radians).
Syntax: - COS ( n )
Example: - The following example returns the cosine of 180 degrees:
SELECT COS(180 * 3.14159265359/180) "Cosine of 180 degrees" FROM DUAL;
Cosine of 180 degrees
---------------------
-1
EXP: - It returns e raised to the nth power, where e = 2.71828183 ...
Syntax: - EXP ( n )
Example: - The following example returns e to the 4th power:
SELECT EXP(4) "e to the 4th power" FROM DUAL;
e to the 4th power
------------------
54.59815
FLOOR: - It returns largest integer equal to or less than n.
Syntax: - FLOOR ( n )
Example: - The following example returns the largest integer equal to or less than 15.7:
SELECT FLOOR(15.7) "Floor" FROM DUAL;
Floor
----------
15
POWER: - It returns m raised to the nth power. The base m and the exponent n can be any numbers, but if m is negative, then n must be an integer.
Syntax: - POWER ( m , n )
Example: - The following example returns 3 squared:
SELECT POWER(3,2) "Raised" FROM DUAL;
Raised
----------
9
ROUND (number): - It returns number rounded to integer places right of the decimal point. If integer is omitted, then number is rounded to 0 places. integer can be negative to round off digits left of the decimal point. integer must be an integer.
Syntax: - ROUND ( number , integer )
Example: - The following example rounds a number to one decimal point:
SELECT ROUND(15.193,1) "Round" FROM DUAL;
Round
----------
15.2
The following example rounds a number one digit to the left of the decimal point:
SELECT ROUND(15.193,-1) "Round" FROM DUAL;
Round
----------
20
SIGN: - It returns -1 if n<0, then . If n=0, then the function returns 0. If n>0, then SIGN returns 1.
Syntax: - SIGN ( n )
Example: - The following example indicates that the function’s argument (-15) is <0:
SELECT SIGN(-15) "Sign" FROM DUAL;
Sign
----------
-1
SIN: - It returns the sine of n (an angle expressed in radians).
Syntax: - SIN ( n )
Example: - The following example returns the sin of 30 degrees:
SELECT SIN(30 * 3.14159265359/180) "Sine of 30 degrees" FROM DUAL;
Sine of 30 degrees
------------------
.5
SQRT: - It returns the square root of n. The value n cannot be negative. SQRT returns a real number.
Syntax: - SQRT ( n )
Example: - The following example returns the square root of 26:
SELECT SQRT(26) "Square root" FROM DUAL;
Square root
-----------
5.09901951
TAN: - It returns the tangent of n (an angle expressed in radians).
Syntax: - TAN ( n )
Example: - The following example returns the tangent of 135 degrees:
SELECT TAN(135 * 3.14159265359/180) "Tangent of 135 degrees" FROM DUAL;
Tangent of 135 degrees
----------------------
- 1
TRUNC (number): - The TRUNC (number) function returns n truncated to m decimal places. If m is omitted, then n is truncated to 0 places. m can be negative to truncate (make zero) m digits left of the decimal point.
Syntax: - TRUNC ( n , m )
Example: - The following example truncate numbers:
SELECT TRUNC(15.79,1) "Truncate" FROM DUAL;
Truncate
----------
15.7
SELECT TRUNC(15.79,-1) "Truncate" FROM DUAL;
Truncate
----------
10





