SQLite degrees() Function
The SQLite degrees()
function converts the specified radian value to a degree value and returns the result.
If you need to convert degrees to radians, use the radians()
function.
Syntax
Here is the syntax of the SQLite degrees()
function:
degrees(radians)
Parameters
radians
-
Required. A radian value.
Return value
The SQLite degrees()
function converts the specified radian value to a degree value and returns the result.
The SQLite degrees()
function will return NULL
if the parameter is NULL
.
The SQLite degrees()
function will return NULL
if you provide a parameter that is not a numeric value.
Examples
This example shows the basic usage of the SQLite degrees()
function:
SELECT
degrees(0),
degrees(pi()),
degrees(3*pi()),
degrees(-3*pi());
degrees(0) = 0.0
degrees(pi()) = 180.0
degrees(3*pi()) = 540.0
degrees(-3*pi()) = -540.0
This uses the pi()
function to get the value of π.