RADIANS
Descriptionβ
Returns the value of x
in radians, converted from degrees to radians.
Syntaxβ
RADIANS(<x>)
Parametersβ
Parameter | Description |
---|---|
<x> | The angle in degrees to be converted. |
Return valueβ
Returns an integer or a floating-point number. Special case:
- If the parameter x is NULL, it returns NULL.
Exampleβ
select radians(0);
+----------------------------+
| radians(cast(0 as DOUBLE)) |
+----------------------------+
| 0.0 |
+----------------------------+
select radians(30);
+-----------------------------+
| radians(cast(30 as DOUBLE)) |
+-----------------------------+
| 0.5235987755982988 |
+-----------------------------+
select radians(90);
+-----------------------------+
| radians(cast(90 as DOUBLE)) |
+-----------------------------+
| 1.5707963267948966 |
+-----------------------------+