--- description: "SQRT (Transact-SQL)" title: "SQRT (Transact-SQL) | Microsoft Docs" ms.custom: "" ms.date: "03/03/2017" ms.prod: sql ms.prod_service: "database-engine, sql-database, sql-data-warehouse, pdw" ms.reviewer: "" ms.technology: t-sql ms.topic: reference f1_keywords: - "SQRT" - "SQRT_TSQL" dev_langs: - "TSQL" helpviewer_keywords: - "SQRT function" - "square root values" ms.assetid: 26e244e8-e82d-4664-a445-1226230ee1c5 author: julieMSFT ms.author: jrasnick monikerRange: ">=aps-pdw-2016||=azuresqldb-current||=azure-sqldw-latest||>=sql-server-2016||>=sql-server-linux-2017||=azuresqldb-mi-current" --- # SQRT (Transact-SQL) [!INCLUDE [sql-asdb-asdbmi-asa-pdw](../../includes/applies-to-version/sql-asdb-asdbmi-asa-pdw.md)] Returns the square root of the specified float value. ![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 ```syntaxsql SQRT ( float_expression ) ``` [!INCLUDE[sql-server-tsql-previous-offline-documentation](../../includes/sql-server-tsql-previous-offline-documentation.md)] ## Arguments *float_expression* Is an [expression](../../t-sql/language-elements/expressions-transact-sql.md) of type **float** or of a type that can be implicitly converted to float. ## Return Types **float** ## Examples The following example returns the square root of numbers between `1.00` and `10.00`. ```sql DECLARE @myvalue FLOAT; SET @myvalue = 1.00; WHILE @myvalue < 10.00 BEGIN SELECT SQRT(@myvalue); SET @myvalue = @myvalue + 1 END; GO ``` [!INCLUDE[ssResult](../../includes/ssresult-md.md)] ``` ------------------------ 1.0 ------------------------ 1.4142135623731 ------------------------ 1.73205080756888 ------------------------ 2.0 ------------------------ 2.23606797749979 ------------------------ 2.44948974278318 ------------------------ 2.64575131106459 ------------------------ 2.82842712474619 ------------------------ 3.0 ``` ## Examples: [!INCLUDE[ssSDWfull](../../includes/sssdwfull-md.md)] and [!INCLUDE[ssPDW](../../includes/sspdw-md.md)] The following example returns the square root of numbers `1.00` and `10.00`. ```sql SELECT SQRT(1.00), SQRT(10.00); ``` [!INCLUDE[ssResult](../../includes/ssresult-md.md)] ``` ---------- ------------ 1.00 3.16 ``` ## See Also [Mathematical Functions (Transact-SQL)](../../t-sql/functions/mathematical-functions-transact-sql.md)