針對以弧度指定的角度,傳回對應的角度。
Transact-SQL 語法慣例
DEGREES ( numeric_expression )
numeric_expression
這是精確數值或近似數值資料類型類別目錄的運算式,但 bit 資料類型除外。
傳回與 numeric_expression 相同的類型。
下列範例會傳回 PI/2 弧度中的角度度數。
SELECT 'The number of degrees in PI/2 radians is: ' + CONVERT(varchar, DEGREES((PI()/2))); GO
以下為結果集:
The number of degrees in PI/2 radians is 90 (1 row(s) affected)