ODBC Server Reference Manual

Transact-SQL Language
HP NonStop ODBC Server Reference Manual429151-002
4-12
Data Types
Variable Names
For variable names, you specify Transact-SQL variable names, which are identifiers of
no more than 29 characters preceded by an “at” symbol (@). The NonStop ODBC
Server retains the variable name but does not map it because variable names are not
used in NonStop SQL/MP.
Data Types
When creating and manipulating objects and data items, you must specify
Transact-SQL data types. Because Transact-SQL and NonStop SQL/MP data types
differ, the data types or values you specify are converted to corresponding NonStop
SQL/MP data types.
Even if you are retrieving or manipulating data created with NonStop SQL/MP, you
must specify Transact-SQL, not NonStop SQL/MP, data types and values.
This subsection summarizes NonStop ODBC Server support of Transact-SQL data
types. Data type support falls in two categories:
Creating objects and data
Retrieving and manipulating NonStop SQL/MP objects and data
Creating Objects and Data
When you create objects and data, you specify Transact-SQL data types and values.
The NonStop ODBC Server handles the type or value in one of three ways:
Fully supports it—the data type or value is processed as you input it.
Converts it—the data type or value is converted to a corresponding NonStop
SQL/MP data type or value.
Flags it as an error—the data type is not supported.
Table 4-4 summarizes the Transact-SQL data types, the corresponding NonStop
SQL/MP data types, and the conversion information.
Table 4-4. Conversion of Transact-SQL Data Types to NonStop SQL/MP Data
Types
Transact-SQL
Data Type
NonStop ODBC
Server Support Corresponding NonStop SQL/MP Data Type
BINARY
BIT x SMALLINT
CHAR x CHAR
DATETIME x DATETIME year to fraction (3)
FLOAT x DOUBLE PRECISION