SMALLINT


SMALLINT.png


The arguments are defined as follows:

numericExpression

numericExpression must be of data type INTEGER. Other data types are not allowed but can be converted to an integer using the INT() function.

If the result of the conversion exceeds the allowable values for a SMALLINT, an overflow condition occurs. The valid range is -32768 through 32767.

Warning

Important

If the argument is a constant, then it must adhere to integer value rules. Specifying SMALLINT(1.5) causes an error because 1.5 is not an integer.

stringExpression

A string expression can be in any external numerical format. It is first converted to its corresponding format, then converted to a SMALLINT. If the CCSID of the string is not in EBCDIC encoding scheme, it is cast to EBCDIC CCSID(37) before conversion takes place.

Warning

Important

If the argument can be null, the result can be null; if the argument value is null, the result is the null value.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

BMC AMI Check for Db2 13.1