Professional Documents
Culture Documents
Arthemetic Operators&&number Functions
Arthemetic Operators&&number Functions
NAME ID SALARY
---------- ---------- ----------
subhash 547 53240
koushik 546 39930
konda 545 26620
+operator:
SQL> select id+500 from emp;
ID+500
----------
1047
1046
1045
-operator:
SQL> select salary-20000 from emp;
SALARY-20000
------------
33240
19930
6620
/operator:
SQL> select salary/2 from emp;
SALARY/2
----------
26620
19965
13310
*operator:
SQL> select id*2 from emp;
ID*2
----------
1094
1092
1090
SQL> select round(77.3456,2) from dual;
ROUND(77.3456,2)
----------------
77.35
SQL> select round(77.3456) from dual;
ROUND(77.3456)
--------------
77
SQL> select floor(77.3456) from dual;
FLOOR(77.3456)
--------------
77
SQL> select mod(77.3456,77) from dual;
MOD(77.3456,77)
---------------
.3456
POWER(7,3)
----------
343
POWER(7,-1)
-----------
.142857143
SQRT(2)
----------
1.41421356
SQL> select abs(77.3456) from dual;
ABS(77.3456)
------------
77.3456