SqlPrType$

Converts a SQL Server token value to a string.

Syntax

SqlPrType$ ( token% )

where

token%
Is the SQL Server token value.

Returns

A string that is the readable translation of the SQL Server token value. When token% is unknown, SqlPrType$ returns an empty string. The strings correspond to SQL Server datatype names.

Remarks

Functions such as SqlColType% and SqlAltType% return SQL Server token values. Use SqlPrType$ to get the string translation of the token value.

The following table shows the token values used by SqlPrType$:

Token value Datatype
SQLINT1 tinyint
SQLINT2 smallint
SQLINT4 int
SQLMONEY money
SQLMONEY4 smallmoney
SLQFLT4 real
SLQFLT8 float
SQLDATETIME datetime
SQLDATETIM4 smalldatetime
SQLBIT bit
SQLCHAR char
SQLVARCHAR varchar
SQLTEXT text
SQLBINARY binary
SQLVARBINARY varbinary
SQLIMAGE image
SQLDECIMAL decimal
SQLNUMERIC numeric
SQLINTN integer-null
SQLDATETIMN datetime-null
SQLMONEYN money-null
SQLFLTN float-null
SQLAOPSUM sum
SQLAOPAVG avg
SQLAOPCNT count
SQLAOPMIN min
SQLAOPMAX max

See Also

SqlAltOp%, SqlAltType%, SqlColType%