All the fuctions here are located in RDM SQL API Library. Linker option: More...
Modules |
|
| SQL API Proprietary Functions | |
| All the fuctions here are located in RDM SQL API Library. Linker option: | |
| SQL CLI Extension Functions | |
Functions |
|
| SQLRETURN | SQLAllocHandle (SQLSMALLINT HandleType, SQLHANDLE InputHandle, SQLHANDLE *OutputHandle) |
| Allocate a resource and assign a handle to it. More... | |
| SQLRETURN | SQLBindCol (SQLHSTMT StatementHandle, SQLUSMALLINT ColumnNumber, SQLSMALLINT TargetType, SQLPOINTER TargetValue, SQLINTEGER BufferLength, SQLINTEGER *StrLen_or_Ind) |
| Bind an application variable to the column. More... | |
| SQLRETURN | SQLCancel (SQLHSTMT StatementHandle) |
| Cancel a statement processing. More... | |
| SQLRETURN | SQLCloseCursor (SQLHSTMT StatementHandle) |
| Close a cursor. More... | |
| SQLRETURN | SQLColAttribute (SQLHSTMT StatementHandle, SQLUSMALLINT ColumnNumber, SQLUSMALLINT FieldIdentifier, SQLPOINTER CharacterAttributePtr, SQLSMALLINT BufferLength, SQLSMALLINT *StringLength, SQLINTEGER *NumericAttributePtr) |
| Retrieve attributes of a column. More... | |
| SQLRETURN | SQLColumns (SQLHSTMT StatementHandle, SQLCHAR *CatalogName, SQLSMALLINT NameLength1, SQLCHAR *SchemaName, SQLSMALLINT NameLength2, SQLCHAR *TableName, SQLSMALLINT NameLength3, SQLCHAR *ColumnName, SQLSMALLINT NameLength4) |
| Retrieve the list of column names for a table. More... | |
| SQLRETURN | SQLConnect (SQLHDBC ConnectionHandle, const SQLCHAR *ServerName, SQLSMALLINT NameLength1, const SQLCHAR *UserName, SQLSMALLINT NameLength2, const SQLCHAR *Authentication, SQLSMALLINT NameLength3) |
| Establish a connection to the database source. More... | |
| SQLRETURN | SQLCopyDesc (SQLHDESC SourceDescHandle, SQLHDESC TargetDescHandle) |
| Copy one descriptor to another. More... | |
| SQLRETURN | SQLDataSources (SQLHENV EnvironmentHandle, SQLUSMALLINT Direction, SQLCHAR *ServerName, SQLSMALLINT BufferLength1, SQLSMALLINT *NameLength1, SQLCHAR *Description, SQLSMALLINT BufferLength2, SQLSMALLINT *NameLength2) |
| Browse data sources. More... | |
| SQLRETURN | SQLDescribeCol (SQLHSTMT StatementHandle, SQLUSMALLINT ColumnNumber, SQLCHAR *ColumnName, SQLSMALLINT BufferLength, SQLSMALLINT *NameLengthPtr, SQLSMALLINT *DataTypePtr, SQLUINTEGER *ColumnSizePtr, SQLSMALLINT *DecimalDigitsPtr, SQLSMALLINT *NullablePtr) |
| Retrieve the detailed description of a column. More... | |
| SQLRETURN | SQLDisconnect (SQLHDBC ConnectionHandle) |
| Disconnect from the database source. More... | |
| SQLRETURN | SQLEndTran (SQLSMALLINT HandleType, SQLHANDLE Handle, SQLSMALLINT CompletionType) |
| Commit or rollback a transaction. More... | |
| SQLRETURN | SQLExecDirect (SQLHSTMT StatementHandle, const SQLCHAR *StatementText, SQLINTEGER TextLength) |
| Prepare and execute an SQL statement. More... | |
| SQLRETURN | SQLExecute (SQLHSTMT StatementHandle) |
| Execute a prepared SQL statement. More... | |
| SQLRETURN | SQLFetch (SQLHSTMT StatementHandle) |
| Fetch the next set of rows from the result set. More... | |
| SQLRETURN | SQLFetchScroll (SQLHSTMT StatementHandle, SQLSMALLINT FetchOrientation, SQLINTEGER FetchOffset) |
| Fetch the next set of rows from the result set. More... | |
| SQLRETURN | SQLFreeHandle (SQLSMALLINT HandleType, SQLHANDLE Handle) |
| Free a SQL API handle. More... | |
| SQLRETURN | SQLFreeStmt (SQLHSTMT StatementHandle, SQLUSMALLINT Option) |
| Stops a statement processing. More... | |
| SQLRETURN | SQLGetConnectAttr (SQLHDBC ConnectionHandle, SQLINTEGER Attribute, SQLPOINTER Value, SQLINTEGER BufferLength, SQLINTEGER *StringLength) |
| Obtain an attribute of the SQL API connection. More... | |
| SQLRETURN | SQLGetCursorName (SQLHSTMT StatementHandle, SQLCHAR *CursorName, SQLSMALLINT BufferLength, SQLSMALLINT *NameLength) |
| Obtain the name of the current open cursor. More... | |
| SQLRETURN | SQLGetData (SQLHSTMT StatementHandle, SQLUSMALLINT ColumnNumber, SQLSMALLINT TargetType, SQLPOINTER TargetValue, SQLINTEGER BufferLength, SQLINTEGER *StrLen_or_Ind) |
| Fetch a single next row from the result set. More... | |
| SQLRETURN | SQLGetDescField (SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber, SQLSMALLINT FieldIdentifier, SQLPOINTER Value, SQLINTEGER BufferLength, SQLINTEGER *StringLength) |
| Obtain the information about a single descriptor header/record field. More... | |
| SQLRETURN | SQLGetDescRec (SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber, SQLCHAR *Name, SQLSMALLINT BufferLength, SQLSMALLINT *StringLengthPtr, SQLSMALLINT *TypePtr, SQLSMALLINT *SubTypePtr, SQLINTEGER *LengthPtr, SQLSMALLINT *PrecisionPtr, SQLSMALLINT *ScalePtr, SQLSMALLINT *NullablePtr) |
| Obtain the information about multiple descriptor header/record fields. More... | |
| SQLRETURN | SQLGetDiagField (SQLSMALLINT HandleType, SQLHANDLE Handle, SQLSMALLINT RecNumber, SQLSMALLINT DiagIdentifier, SQLPOINTER DiagInfo, SQLSMALLINT BufferLength, SQLSMALLINT *StringLength) |
| Obtain the information about a single diagnostic record field. More... | |
| SQLRETURN | SQLGetDiagRec (SQLSMALLINT HandleType, SQLHANDLE Handle, SQLSMALLINT RecNumber, SQLCHAR *Sqlstate, SQLINTEGER *NativeError, SQLCHAR *MessageText, SQLSMALLINT BufferLength, SQLSMALLINT *TextLength) |
| Obtain the information about multiple diagnostic record fields. More... | |
| SQLRETURN | SQLGetEnvAttr (SQLHENV EnvironmentHandle, SQLINTEGER Attribute, SQLPOINTER Value, SQLINTEGER BufferLength, SQLINTEGER *StringLength) |
| Obtain an attribute of an SQL API environment. More... | |
| SQLRETURN | SQLGetFunctions (SQLHDBC ConnectionHandle, SQLUSMALLINT FunctionId, SQLUSMALLINT *Supported) |
| Return whether or not a specific SQL API function is supported. More... | |
| SQLRETURN | SQLGetInfo (SQLHDBC ConnectionHandle, SQLUSMALLINT InfoType, SQLPOINTER InfoValue, SQLSMALLINT BufferLength, SQLSMALLINT *StringLength) |
| Return the information about the SQL API driver and data source. More... | |
| SQLRETURN | SQLGetStmtAttr (SQLHSTMT StatementHandle, SQLINTEGER Attribute, SQLPOINTER Value, SQLINTEGER BufferLength, SQLINTEGER *StringLength) |
| Obtain an attribute of an SQL API statement. More... | |
| SQLRETURN | SQLGetTypeInfo (SQLHSTMT StatementHandle, SQLSMALLINT DataType) |
| Return the information about the SQL API data types. More... | |
| SQLRETURN | SQLNumResultCols (SQLHSTMT StatementHandle, SQLSMALLINT *ColumnCount) |
| Return the number of columns in a result set. More... | |
| SQLRETURN | SQLParamData (SQLHSTMT StatementHandle, SQLPOINTER *Value) |
| Retrieve parameter data for the statement waiting to be executed. More... | |
| SQLRETURN | SQLPrepare (SQLHSTMT StatementHandle, const SQLCHAR *StatementText, SQLINTEGER TextLength) |
| Prepare an SQL statement. More... | |
| SQLRETURN | SQLPutData (SQLHSTMT StatementHandle, SQLPOINTER Data, SQLINTEGER StrLen_or_Ind) |
| Send parameterised data for insert/update. More... | |
| SQLRETURN | SQLRowCount (SQLHSTMT StatementHandle, SQLINTEGER *RowCount) |
| Return the number of rows affected by INSERT/UPDATE/DELETE. More... | |
| SQLRETURN | SQLSetConnectAttr (SQLHDBC ConnectionHandle, SQLINTEGER Attribute, SQLPOINTER Value, SQLINTEGER StringLength) |
| Set an attribute of the SQL API connection. More... | |
| SQLRETURN | SQLSetCursorName (SQLHSTMT StatementHandle, const SQLCHAR *CursorName, SQLSMALLINT NameLength) |
| Set the name of the current open cursor. More... | |
| SQLRETURN | SQLSetDescField (SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber, SQLSMALLINT FieldIdentifier, SQLPOINTER Value, SQLINTEGER BufferLength) |
| Set the value of a single descriptor record field. More... | |
| SQLRETURN | SQLSetDescRec (SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber, SQLSMALLINT Type, SQLSMALLINT SubType, SQLINTEGER Length, SQLSMALLINT Precision, SQLSMALLINT Scale, SQLPOINTER Data, SQLINTEGER *StringLength, SQLINTEGER *Indicator) |
| Set the value of multiple descriptor record fields. More... | |
| SQLRETURN | SQLSetEnvAttr (SQLHENV EnvironmentHandle, SQLINTEGER Attribute, SQLPOINTER Value, SQLINTEGER StringLength) |
| Obtain an attribute of an SQL API environment. More... | |
| SQLRETURN | SQLSetStmtAttr (SQLHSTMT StatementHandle, SQLINTEGER Attribute, SQLPOINTER Value, SQLINTEGER StringLength) |
| Set an attribute of an SQL API statement. More... | |
| SQLRETURN | SQLSpecialColumns (SQLHSTMT StatementHandle, SQLUSMALLINT IdentifierType, SQLCHAR *CatalogName, SQLSMALLINT NameLength1, SQLCHAR *SchemaName, SQLSMALLINT NameLength2, SQLCHAR *TableName, SQLSMALLINT NameLength3, SQLUSMALLINT Scope, SQLUSMALLINT Nullable) |
| Retrieve the information about special columns. More... | |
| SQLRETURN | SQLStatistics (SQLHSTMT StatementHandle, SQLCHAR *CatalogName, SQLSMALLINT NameLength1, SQLCHAR *SchemaName, SQLSMALLINT NameLength2, SQLCHAR *TableName, SQLSMALLINT NameLength3, SQLUSMALLINT Unique, SQLUSMALLINT Reserved) |
| Retrieve the statistics about the specified tables. More... | |
| SQLRETURN | SQLTables (SQLHSTMT StatementHandle, SQLCHAR *CatalogName, SQLSMALLINT NameLength1, SQLCHAR *SchemaName, SQLSMALLINT NameLength2, SQLCHAR *TableName, SQLSMALLINT NameLength3, SQLCHAR *TableType, SQLSMALLINT NameLength4) |
| Retrieve the list of table names for a catalog/database. More... | |
| SQLRETURN | SQLNumParams (SQLHSTMT StatementHandle, SQLSMALLINT *ParameterCountPtr) |
| Return the number of parameters in an SQL statement. More... | |
Detailed Description
All the fuctions here are located in RDM SQL API Library. Linker option:
All the fuctions here are located in RDM SQL API Library. Linker option:
-lrdmrdbc
.
-lrdmrdbc
.
Function Documentation
SQLAllocHandle()
| SQLRETURN SQLAllocHandle | ( | SQLSMALLINT | HandleType, |
| SQLHANDLE | InputHandle, | ||
| SQLHANDLE * | OutputHandle | ||
| ) |
#include <sql.h>
Allocate a resource and assign a handle to it.
| HandleType | InputHandle Type | Description |
|---|---|---|
| SQL_HANDLE_ENV | SQL_NULL_HANDLE | The environment handle is always associated with a SQL_NULL_HANDLE type. |
| SQL_HANDLE_DBC | SQL_HANDLE_ENV | The connection handle is associated with an environment handle. |
| SQL_HANDLE_STMT | SQL_HANDLE_DBC | The statement handle is associated with a connection handle. |
| SQL_HANDLE_DESC | SQL_HANDLE_DBC | The descriptor handle is associated with a connection handle. |
- Return values
-
SQL_SUCCESS Function completed successfully. SQL_SUCCESS_WITH_INFO Function completed successfully, with a nonfatal status information. \ Use the SQLGetDiagRec() function to retrieve the additional information. SQL_INVALID_HANDLE Function failed because an invalid environment, connection, \ statement, or descriptor handle was provided as an argument. SQL_ERROR Function failed. Use the SQLGetDiagRec() function to retrieve the error information.
- Note
-
When allocating a handle other than an environment handle, if SQLAllocHandle() returns SQL_ERROR, it sets OutputHandle to
SQL_NULL_HDBC,SQL_NULL_HSTMT, orSQL_NULL_HDESC, depending on the value of HandleType, unless the output argument is a null pointer. The application can then obtain additional information from the diagnostic data structure associated with the handle in the InputHandle argument.
- Parameters
-
[in] HandleType [in] Type of handle to be allocated [in] InputHandle [in] Allocated input handle in whose context new handle will be allocated [out] OutputHandle [out] Pointer to buffer to contain allocated handle structure
SQLBindCol()
| SQLRETURN SQLBindCol | ( | SQLHSTMT | StatementHandle, |
| SQLUSMALLINT | ColumnNumber, | ||
| SQLSMALLINT | TargetType, | ||
| SQLPOINTER | TargetValue, | ||
| SQLINTEGER | BufferLength, | ||
| SQLINTEGER * | StrLen_or_Ind | ||
| ) |
#include <sql.h>
Bind an application variable to the column.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLCancel()
#include <sql.h>
Cancel a statement processing.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLCloseCursor()
SQLColAttribute()
| SQLRETURN SQLColAttribute | ( | SQLHSTMT | StatementHandle, |
| SQLUSMALLINT | ColumnNumber, | ||
| SQLUSMALLINT | FieldIdentifier, | ||
| SQLPOINTER | CharacterAttributePtr, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | StringLength, | ||
| SQLINTEGER * | NumericAttributePtr | ||
| ) |
#include <sql.h>
Retrieve attributes of a column.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLColumns()
| SQLRETURN SQLColumns | ( | SQLHSTMT | StatementHandle, |
| SQLCHAR * | CatalogName, | ||
| SQLSMALLINT | NameLength1, | ||
| SQLCHAR * | SchemaName, | ||
| SQLSMALLINT | NameLength2, | ||
| SQLCHAR * | TableName, | ||
| SQLSMALLINT | NameLength3, | ||
| SQLCHAR * | ColumnName, | ||
| SQLSMALLINT | NameLength4 | ||
| ) |
#include <sql.h>
Retrieve the list of column names for a table.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLConnect()
| SQLRETURN SQLConnect | ( | SQLHDBC | ConnectionHandle, |
| const SQLCHAR * | ServerName, | ||
| SQLSMALLINT | NameLength1, | ||
| const SQLCHAR * | UserName, | ||
| SQLSMALLINT | NameLength2, | ||
| const SQLCHAR * | Authentication, | ||
| SQLSMALLINT | NameLength3 | ||
| ) |
#include <sql.h>
Establish a connection to the database source.
- Parameters
-
[in] ConnectionHandle [in] Allocated connection handle
SQLCopyDesc()
#include <sql.h>
Copy one descriptor to another.
SQLDataSources()
| SQLRETURN SQLDataSources | ( | SQLHENV | EnvironmentHandle, |
| SQLUSMALLINT | Direction, | ||
| SQLCHAR * | ServerName, | ||
| SQLSMALLINT | BufferLength1, | ||
| SQLSMALLINT * | NameLength1, | ||
| SQLCHAR * | Description, | ||
| SQLSMALLINT | BufferLength2, | ||
| SQLSMALLINT * | NameLength2 | ||
| ) |
#include <sql.h>
Browse data sources.
- Parameters
-
[in] EnvironmentHandle [in] Allocated environment handle
SQLDescribeCol()
| SQLRETURN SQLDescribeCol | ( | SQLHSTMT | StatementHandle, |
| SQLUSMALLINT | ColumnNumber, | ||
| SQLCHAR * | ColumnName, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | NameLengthPtr, | ||
| SQLSMALLINT * | DataTypePtr, | ||
| SQLUINTEGER * | ColumnSizePtr, | ||
| SQLSMALLINT * | DecimalDigitsPtr, | ||
| SQLSMALLINT * | NullablePtr | ||
| ) |
#include <sql.h>
Retrieve the detailed description of a column.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLDisconnect()
#include <sql.h>
Disconnect from the database source.
SQLEndTran()
| SQLRETURN SQLEndTran | ( | SQLSMALLINT | HandleType, |
| SQLHANDLE | Handle, | ||
| SQLSMALLINT | CompletionType | ||
| ) |
#include <sql.h>
Commit or rollback a transaction.
SQLExecDirect()
| SQLRETURN SQLExecDirect | ( | SQLHSTMT | StatementHandle, |
| const SQLCHAR * | StatementText, | ||
| SQLINTEGER | TextLength | ||
| ) |
#include <sql.h>
Prepare and execute an SQL statement.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLExecute()
#include <sql.h>
Execute a prepared SQL statement.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLFetch()
#include <sql.h>
Fetch the next set of rows from the result set.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLFetchScroll()
| SQLRETURN SQLFetchScroll | ( | SQLHSTMT | StatementHandle, |
| SQLSMALLINT | FetchOrientation, | ||
| SQLINTEGER | FetchOffset | ||
| ) |
#include <sql.h>
Fetch the next set of rows from the result set.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLFreeHandle()
| SQLRETURN SQLFreeHandle | ( | SQLSMALLINT | HandleType, |
| SQLHANDLE | Handle | ||
| ) |
#include <sql.h>
Free a SQL API handle.
SQLFreeStmt()
| SQLRETURN SQLFreeStmt | ( | SQLHSTMT | StatementHandle, |
| SQLUSMALLINT | Option | ||
| ) |
#include <sql.h>
Stops a statement processing.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLGetConnectAttr()
| SQLRETURN SQLGetConnectAttr | ( | SQLHDBC | ConnectionHandle, |
| SQLINTEGER | Attribute, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | BufferLength, | ||
| SQLINTEGER * | StringLength | ||
| ) |
#include <sql.h>
Obtain an attribute of the SQL API connection.
- Parameters
-
[in] ConnectionHandle [in] Allocated connection handle
SQLGetCursorName()
| SQLRETURN SQLGetCursorName | ( | SQLHSTMT | StatementHandle, |
| SQLCHAR * | CursorName, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | NameLength | ||
| ) |
#include <sql.h>
Obtain the name of the current open cursor.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLGetData()
| SQLRETURN SQLGetData | ( | SQLHSTMT | StatementHandle, |
| SQLUSMALLINT | ColumnNumber, | ||
| SQLSMALLINT | TargetType, | ||
| SQLPOINTER | TargetValue, | ||
| SQLINTEGER | BufferLength, | ||
| SQLINTEGER * | StrLen_or_Ind | ||
| ) |
#include <sql.h>
Fetch a single next row from the result set.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLGetDescField()
| SQLRETURN SQLGetDescField | ( | SQLHDESC | DescriptorHandle, |
| SQLSMALLINT | RecNumber, | ||
| SQLSMALLINT | FieldIdentifier, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | BufferLength, | ||
| SQLINTEGER * | StringLength | ||
| ) |
#include <sql.h>
Obtain the information about a single descriptor header/record field.
- Parameters
-
[in] DescriptorHandle [in] Allocated descriptor handle
SQLGetDescRec()
| SQLRETURN SQLGetDescRec | ( | SQLHDESC | DescriptorHandle, |
| SQLSMALLINT | RecNumber, | ||
| SQLCHAR * | Name, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | StringLengthPtr, | ||
| SQLSMALLINT * | TypePtr, | ||
| SQLSMALLINT * | SubTypePtr, | ||
| SQLINTEGER * | LengthPtr, | ||
| SQLSMALLINT * | PrecisionPtr, | ||
| SQLSMALLINT * | ScalePtr, | ||
| SQLSMALLINT * | NullablePtr | ||
| ) |
#include <sql.h>
Obtain the information about multiple descriptor header/record fields.
- Parameters
-
[in] DescriptorHandle [in] Allocated descriptor handle
SQLGetDiagField()
| SQLRETURN SQLGetDiagField | ( | SQLSMALLINT | HandleType, |
| SQLHANDLE | Handle, | ||
| SQLSMALLINT | RecNumber, | ||
| SQLSMALLINT | DiagIdentifier, | ||
| SQLPOINTER | DiagInfo, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | StringLength | ||
| ) |
#include <sql.h>
Obtain the information about a single diagnostic record field.
SQLGetDiagRec()
| SQLRETURN SQLGetDiagRec | ( | SQLSMALLINT | HandleType, |
| SQLHANDLE | Handle, | ||
| SQLSMALLINT | RecNumber, | ||
| SQLCHAR * | Sqlstate, | ||
| SQLINTEGER * | NativeError, | ||
| SQLCHAR * | MessageText, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | TextLength | ||
| ) |
#include <sql.h>
Obtain the information about multiple diagnostic record fields.
- Note
- Possible return values for NativeError will be RDM_RETCODE values.
SQLGetEnvAttr()
| SQLRETURN SQLGetEnvAttr | ( | SQLHENV | EnvironmentHandle, |
| SQLINTEGER | Attribute, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | BufferLength, | ||
| SQLINTEGER * | StringLength | ||
| ) |
#include <sql.h>
Obtain an attribute of an SQL API environment.
- Parameters
-
[in] EnvironmentHandle [in] Allocated environment handle
SQLGetFunctions()
| SQLRETURN SQLGetFunctions | ( | SQLHDBC | ConnectionHandle, |
| SQLUSMALLINT | FunctionId, | ||
| SQLUSMALLINT * | Supported | ||
| ) |
#include <sql.h>
Return whether or not a specific SQL API function is supported.
- Parameters
-
[in] ConnectionHandle [in] Allocated connection handle
SQLGetInfo()
| SQLRETURN SQLGetInfo | ( | SQLHDBC | ConnectionHandle, |
| SQLUSMALLINT | InfoType, | ||
| SQLPOINTER | InfoValue, | ||
| SQLSMALLINT | BufferLength, | ||
| SQLSMALLINT * | StringLength | ||
| ) |
#include <sql.h>
Return the information about the SQL API driver and data source.
- Parameters
-
[in] ConnectionHandle [in] Allocated connection handle
SQLGetStmtAttr()
| SQLRETURN SQLGetStmtAttr | ( | SQLHSTMT | StatementHandle, |
| SQLINTEGER | Attribute, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | BufferLength, | ||
| SQLINTEGER * | StringLength | ||
| ) |
#include <sql.h>
Obtain an attribute of an SQL API statement.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLGetTypeInfo()
| SQLRETURN SQLGetTypeInfo | ( | SQLHSTMT | StatementHandle, |
| SQLSMALLINT | DataType | ||
| ) |
#include <sql.h>
Return the information about the SQL API data types.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLNumParams()
| SQLRETURN SQLNumParams | ( | SQLHSTMT | StatementHandle, |
| SQLSMALLINT * | ParameterCountPtr | ||
| ) |
#include <sqlext.h>
Return the number of parameters in an SQL statement.
SQLNumResultCols()
| SQLRETURN SQLNumResultCols | ( | SQLHSTMT | StatementHandle, |
| SQLSMALLINT * | ColumnCount | ||
| ) |
#include <sql.h>
Return the number of columns in a result set.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLParamData()
| SQLRETURN SQLParamData | ( | SQLHSTMT | StatementHandle, |
| SQLPOINTER * | Value | ||
| ) |
#include <sql.h>
Retrieve parameter data for the statement waiting to be executed.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLPrepare()
| SQLRETURN SQLPrepare | ( | SQLHSTMT | StatementHandle, |
| const SQLCHAR * | StatementText, | ||
| SQLINTEGER | TextLength | ||
| ) |
#include <sql.h>
Prepare an SQL statement.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLPutData()
| SQLRETURN SQLPutData | ( | SQLHSTMT | StatementHandle, |
| SQLPOINTER | Data, | ||
| SQLINTEGER | StrLen_or_Ind | ||
| ) |
#include <sql.h>
Send parameterised data for insert/update.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLRowCount()
| SQLRETURN SQLRowCount | ( | SQLHSTMT | StatementHandle, |
| SQLINTEGER * | RowCount | ||
| ) |
#include <sql.h>
Return the number of rows affected by INSERT/UPDATE/DELETE.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLSetConnectAttr()
| SQLRETURN SQLSetConnectAttr | ( | SQLHDBC | ConnectionHandle, |
| SQLINTEGER | Attribute, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | StringLength | ||
| ) |
#include <sql.h>
Set an attribute of the SQL API connection.
- Parameters
-
[in] ConnectionHandle [in] Allocated connection handle
SQLSetCursorName()
| SQLRETURN SQLSetCursorName | ( | SQLHSTMT | StatementHandle, |
| const SQLCHAR * | CursorName, | ||
| SQLSMALLINT | NameLength | ||
| ) |
#include <sql.h>
Set the name of the current open cursor.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLSetDescField()
| SQLRETURN SQLSetDescField | ( | SQLHDESC | DescriptorHandle, |
| SQLSMALLINT | RecNumber, | ||
| SQLSMALLINT | FieldIdentifier, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | BufferLength | ||
| ) |
#include <sql.h>
Set the value of a single descriptor record field.
- Parameters
-
[in] DescriptorHandle [in] Allocated descriptor handle
SQLSetDescRec()
| SQLRETURN SQLSetDescRec | ( | SQLHDESC | DescriptorHandle, |
| SQLSMALLINT | RecNumber, | ||
| SQLSMALLINT | Type, | ||
| SQLSMALLINT | SubType, | ||
| SQLINTEGER | Length, | ||
| SQLSMALLINT | Precision, | ||
| SQLSMALLINT | Scale, | ||
| SQLPOINTER | Data, | ||
| SQLINTEGER * | StringLength, | ||
| SQLINTEGER * | Indicator | ||
| ) |
#include <sql.h>
Set the value of multiple descriptor record fields.
- Parameters
-
[in] DescriptorHandle [in] Allocated descriptor handle
SQLSetEnvAttr()
| SQLRETURN SQLSetEnvAttr | ( | SQLHENV | EnvironmentHandle, |
| SQLINTEGER | Attribute, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | StringLength | ||
| ) |
#include <sql.h>
Obtain an attribute of an SQL API environment.
- Parameters
-
[in] EnvironmentHandle [in] Allocated environment handle
SQLSetStmtAttr()
| SQLRETURN SQLSetStmtAttr | ( | SQLHSTMT | StatementHandle, |
| SQLINTEGER | Attribute, | ||
| SQLPOINTER | Value, | ||
| SQLINTEGER | StringLength | ||
| ) |
#include <sql.h>
Set an attribute of an SQL API statement.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLSpecialColumns()
| SQLRETURN SQLSpecialColumns | ( | SQLHSTMT | StatementHandle, |
| SQLUSMALLINT | IdentifierType, | ||
| SQLCHAR * | CatalogName, | ||
| SQLSMALLINT | NameLength1, | ||
| SQLCHAR * | SchemaName, | ||
| SQLSMALLINT | NameLength2, | ||
| SQLCHAR * | TableName, | ||
| SQLSMALLINT | NameLength3, | ||
| SQLUSMALLINT | Scope, | ||
| SQLUSMALLINT | Nullable | ||
| ) |
#include <sql.h>
Retrieve the information about special columns.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLStatistics()
| SQLRETURN SQLStatistics | ( | SQLHSTMT | StatementHandle, |
| SQLCHAR * | CatalogName, | ||
| SQLSMALLINT | NameLength1, | ||
| SQLCHAR * | SchemaName, | ||
| SQLSMALLINT | NameLength2, | ||
| SQLCHAR * | TableName, | ||
| SQLSMALLINT | NameLength3, | ||
| SQLUSMALLINT | Unique, | ||
| SQLUSMALLINT | Reserved | ||
| ) |
#include <sql.h>
Retrieve the statistics about the specified tables.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle
SQLTables()
| SQLRETURN SQLTables | ( | SQLHSTMT | StatementHandle, |
| SQLCHAR * | CatalogName, | ||
| SQLSMALLINT | NameLength1, | ||
| SQLCHAR * | SchemaName, | ||
| SQLSMALLINT | NameLength2, | ||
| SQLCHAR * | TableName, | ||
| SQLSMALLINT | NameLength3, | ||
| SQLCHAR * | TableType, | ||
| SQLSMALLINT | NameLength4 | ||
| ) |
#include <sql.h>
Retrieve the list of table names for a catalog/database.
- Parameters
-
[in] StatementHandle [in] Allocated statement handle