Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (Français) » UltraLite - Database Management and Reference » UltraLite SQL Reference » UltraLite SQL functions » SQL functions (P-Z)

 

SIGN function [Numeric]

Returns the sign of a number.

Syntax
SIGN( numeric-expression )
Parameters
  • numeric-expression   The number for which the sign is to be returned.

Returns

SMALL INT

Remarks

For negative numbers, the SIGN function returns -1.

For zero, the SIGN function returns 0.

For positive numbers, the SIGN function returns 1.

Standards and compatibility
  • SQL/2003   Vendor extension.

Example

The following statement returns the value -1

SELECT SIGN( -550 );