«Back to Home

Oracle Jump Start

Topics

How To Use ABS Function In OraclePLSQL

ABS
 
This type of function returns the total value of n. This function returns the same data type as the numeric data type of the arguments.
 
Syntax
 
The syntax of ABS function in Oracle/PLSQL is given below:
  1. ABS(number)  
Example
  1. Select ABS(28.53)  
  2. From Dual;  
1
 
Let’s take another example of ABS function, which is given below-

Example
  1. Select ABS(-36)  
  2. from Dual;  
2
 
Example
  1. Select ABS(-35.45)  
  2. From Dual;  
3

Example
  1. select ABS(54.34 * -1)  
  2. from Dual;  
4

Summary
 
Thus, we learnt, ABS function returns the total value of n. This function returns the same data type as the numeric data type of the arguments. We learnt, how to use ABS function in Oracle with the examples.