Data Types (Extended Stored Procedure API)

 
System_CAPS_ICON_important.jpg Important


This feature will be removed in a future version of Microsoft SQL Server. Do not use this feature in new development work, and modify applications that currently use this feature as soon as possible. Use CLR integration instead.

To use the Extended Stored Procedure API data types, include the Srv.h header file in your program.

Data typeSQL Server data typeDescription
SRVBIGBINARYbinarybinary data type, length 0 to 8000 bytes.
SRVBIGCHARcharcharacter data type, length 0 to 8000 bytes.
SRVBIGVARBINARYvarbinaryVariable-length binary data type, length 0 to 8000 bytes.
SRVBIGVARCHARvarcharVariable-length character data type, length 0 to 8000 bytes.
SRVBINARYbinarybinary data type.
SRVBITBitbit data type.
SRVBITNbit nullbit data type, null values allowed.
SRVCHARcharcharacter data type.
SRVDATETIMEdatetime8-byte datetime data type.
SRVDATETIM4smalldatetime4-byte smalldatetime data type.
SRVDATETIMNdatetime nullsmalldatetime or datetime data type, null values allowed.
SRVDECIMALdecimaldecimal data type.
SRVDECIMALNdecimal nulldecimal data type, null values allowed.
SRVFLT4real4-byte real data type.
SRVFLT8float8-byte float data type.
SRVFLTNreal | float nullreal or float data type, null values allowed.
SRVIMAGEimageimage data type.
SRVINT1tinyint1-byte tinyint data type.
SRVINT2smallint2-byte smallint data type.
SRVINT4int4-byte int data type.
SRVINTNtinyint | smallint | int nulltinyint, smallint, or int data type, null values allowed.
SRVMONEY4smallmoney4-byte smallmoney data type.
SRVMONEYmoney8-byte money data type.
SRVMONEYNmoney | smallmoney nullsmallmoney or money data type, null values allowed.
SRVNCHARncharUnicode character data type.
SRVNTEXTntextUnicode text data type.
SRVNUMERICnumericnumeric data type.
SRVNUMERICNnumeric nullnumeric data type, null values allowed.
SRVNVARCHARnvarcharUnicode variable-length character data type.
SRVTEXTtexttext data type.
SRVVARBINARYvarbinaryVariable-length binary data type.
SRVVARCHARvarcharVariable-length character data type.
System_CAPS_ICON_important.jpg Important


You should thoroughly review the source code of extended stored procedures, and you should test the compiled DLLs before you install them on a production server. For information about security review and testing, see this Microsoft Web site.

Community Additions

ADD
Show: