--- title: "ATAN (Transact-SQL) | Microsoft Docs" ms.custom: "" ms.date: "07/24/2017" ms.prod: "sql" ms.prod_service: "database-engine, sql-database, sql-data-warehouse, pdw" ms.service: "" ms.component: "t-sql|functions" ms.reviewer: "" ms.suite: "sql" ms.technology: - "database-engine" ms.tgt_pltfrm: "" ms.topic: "language-reference" f1_keywords: - "ATAN_TSQL" - "ATAN" dev_langs: - "TSQL" helpviewer_keywords: - "arctangent" - "ATAN function" - "tangent" ms.assetid: 6d3dd28e-4fa6-40ba-94cf-b33c0ff614ec caps.latest.revision: 25 author: "edmacauley" ms.author: "edmaca" manager: "craigg" ms.workload: "Inactive" monikerRange: ">= aps-pdw-2016 || = azuresqldb-current || = azure-sqldw-latest || >= sql-server-2016 || = sqlallproducts-allversions" --- # ATAN (Transact-SQL) [!INCLUDE[tsql-appliesto-ss2008-all-md](../../includes/tsql-appliesto-ss2008-all-md.md)] A function that returns the angle, in radians, whose tangent is a specified **float** expression. This is also called arctangent. ![Topic link icon](../../database-engine/configure-windows/media/topic-link.gif "Topic link icon") [Transact-SQL Syntax Conventions](../../t-sql/language-elements/transact-sql-syntax-conventions-transact-sql.md) ## Syntax ```sql ATAN ( float_expression ) ``` ## Arguments *float_expression* An [expression](../../t-sql/language-elements/expressions-transact-sql.md) of either type **float** or of a type that implicitly convert to **float**. ## Return types **float** ## Examples This example takes a **float** expression and returns the ATAN of the specified angle. ```sql SELECT 'The ATAN of -45.01 is: ' + CONVERT(varchar, ATAN(-45.01)) SELECT 'The ATAN of -181.01 is: ' + CONVERT(varchar, ATAN(-181.01)) SELECT 'The ATAN of 0 is: ' + CONVERT(varchar, ATAN(0)) SELECT 'The ATAN of 0.1472738 is: ' + CONVERT(varchar, ATAN(0.1472738)) SELECT 'The ATAN of 197.1099392 is: ' + CONVERT(varchar, ATAN(197.1099392)) GO ``` [!INCLUDE[ssResult](../../includes/ssresult-md.md)] ```sql ------------------------------- The ATAN of -45.01 is: -1.54858 (1 row(s) affected) -------------------------------- The ATAN of -181.01 is: -1.56527 (1 row(s) affected) -------------------------------- The ATAN of 0 is: 0 (1 row(s) affected) ---------------------------------- The ATAN of 0.1472738 is: 0.146223 (1 row(s) affected) ----------------------------------- The ATAN of 197.1099392 is: 1.56572 (1 row(s) affected) ``` ## Examples: [!INCLUDE[ssSDWfull](../../includes/sssdwfull-md.md)] and [!INCLUDE[ssPDW](../../includes/sspdw-md.md)] This example takes a **float** expression and returns the arctangent of the specified angle. ```sql SELECT ATAN(45.87) AS atanCalc1, ATAN(-181.01) AS atanCalc2, ATAN(0) AS atanCalc3, ATAN(0.1472738) AS atanCalc4, ATAN(197.1099392) AS atanCalc5; ``` [!INCLUDE[ssResult](../../includes/ssresult-md.md)] ``` atanCalc1 atanCalc2 atanCalc3 atanCalc4 atanCalc5 --------- --------- --------- --------- --------- 1.55 -1.57 0.00 0.15 1.57 ``` ## See also [CEILING (Transact-SQL)](../../t-sql/functions/ceiling-transact-sql.md) [Mathematical Functions (Transact-SQL)](../../t-sql/functions/mathematical-functions-transact-sql.md)