Mysql Sqrt Function
MySQL: SQRT Function
This tutorial explains how to use the MySQL SQRT function with syntax and examples.
Description
The MySQL SQRT function returns the square root of a number.
Syntax
The syntax for the SQRT function in MySQL is:
Parameters or Arguments
- number
A positive number used to calculate the square root.
Note
- The SQRT function will return NULL, if the number is a negative value.
Applies To
The SQRT function can be used in the following versions of MySQL:
- MySQL 5.7, MySQL 5.6, MySQL 5.5, MySQL 5.1, MySQL 5.0, MySQL 4.1, MySQL 4.0, MySQL 3.23
Example
Let's look at some MySQL SQRT function examples and explore how to use the SQRT function in MySQL.
For example: