SQL Server ABS() Function

Example

Return the absolute value of a number:

SELECT Abs(-243.5) AS AbsNum;
Try it Yourself »

Definition and Usage

The ABS() function returns the absolute value of a number.

Syntax

ABS(number)

Parameter Values

Parameter Description
number Required. A numeric value

Technical Details

Works in: SQL Server (starting with 2008), Azure SQL Database, Azure SQL Data Warehouse, Parallel Data Warehouse

Copyright 1999-2023 by Refsnes Data. All Rights Reserved.