Tutorials Point


  Learning Basic SQL
  Advanced SQL
  SQL Functions
  SQL Useful Resources
  Selected Reading

© 2011 TutorialsPoint.COM


  Home     References     Discussion Forums     About TP  

SQL - Arithmetic Operators


previous next AddThis Social Bookmark Button


Here are simple examples showing usage of SQL Arithmetic Operators:

SQL> select 10+ 20;
+--------+
| 10+ 20 |
+--------+
|     30 |
+--------+
1 row in set (0.00 sec)

SQL> select 10 * 20;
+---------+
| 10 * 20 |
+---------+
|     200 |
+---------+
1 row in set (0.00 sec)

SQL> select 10 / 5;
+--------+
| 10 / 5 |
+--------+
| 2.0000 |
+--------+
1 row in set (0.03 sec)

SQL> select 12 %  5;
+---------+
| 12 %  5 |
+---------+
|       2 |
+---------+
1 row in set (0.00 sec)


previous next Printer Friendly



  

Advertisement

Online Image Processing

Indian Baby Names