ATAN2
The ATAN2
function returns the arc tangent of Expression1
and Expression2
.
SQL syntax
ATAN2(Expression1,Expression2)
Parameters
ATAN2
has the parameters:
Parameter | Description |
---|---|
|
Operand or column can be any numeric data type or any non-numeric data type that can be implicitly converted to a numeric data type. |
|
Operand or column can be any numeric data type or any non-numeric data type that can be implicitly converted to a numeric data type. |
Description
-
Expression1
can be in an unbounded range.ATAN2
returns a value in the range of-pi
topi
depending on the signs ofExpression1
andExpression2
, expressed in radians. -
If
Expression
is of typeNUMBER
, the data type returned isNUMBER
. For all other numeric data types, the data type returned isBINARY_DOUBLE
. -
If the value of
Expression1
orExpression2
isNULL
, or the value of bothExpression1
andExpression2
areNULL
,NULL
is returned.
Example
Use the ATAN2
function to return the arc tangent of .3
and .2
.
Command> SELECT ATAN2(.3,.2) "Arc tangent of .3 and .2" FROM dual; < .9827937232473290679857106110146660144997 > 1 row found.