| title | DEGREES (Transact-SQL) | Microsoft Docs | ||
|---|---|---|---|
| ms.custom | |||
| ms.date | 03/06/2017 | ||
| ms.prod | sql | ||
| ms.prod_service | database-engine, sql-database, sql-data-warehouse, pdw | ||
| ms.reviewer | |||
| ms.technology | t-sql | ||
| ms.topic | language-reference | ||
| f1_keywords |
|
||
| dev_langs |
|
||
| helpviewer_keywords |
|
||
| ms.assetid | 5208de3c-90a3-4f59-a7e3-10b01bf285bb | ||
| author | MikeRayMSFT | ||
| ms.author | mikeray | ||
| monikerRange | >=aps-pdw-2016||=azuresqldb-current||=azure-sqldw-latest||>=sql-server-2016||=sqlallproducts-allversions||>=sql-server-linux-2017||=azuresqldb-mi-current |
[!INCLUDEtsql-appliesto-ss2008-all-md]
This function returns the corresponding angle, in degrees, for an angle specified in radians.
Transact-SQL Syntax Conventions
DEGREES ( numeric_expression )
numeric_expression
An expression of the exact numeric or approximate numeric data type category, except for the bit data type.
Returns a value whose data type matches the data type of numeric_expression.
This example returns the number of degrees in an angle of PI/2 radians.
SELECT 'The number of degrees in PI/2 radians is: ' +
CONVERT(varchar, DEGREES((PI()/2)));
GO
[!INCLUDEssResult]
The number of degrees in PI/2 radians is 90
(1 row(s) affected)