CODBCStmt.GetColumnsmethod
Returns the list of column names in specified tables.
Syntax
FUNCTION GetColumns (BYREF wszCatalogName AS WSTRING, BYVAL CatalogNameLength AS SQLSMALLINT, BYREF wszSchemaName AS WSTRING, BYVAL SchemaNameLength AS SQLSMALLINT, BYREF wszTableName AS WSTRING, BYVAL TableNameLength AS SQLSMALLINT, BYREF wszColumnName AS WSTRING, BYVAL ColumnNameLength AS SQLSMALLINT) AS SQLRETURN
Parameters
| Name | Description | |
|---|---|---|
wszCatalogName | Catalog name. If a driver supports names for some catalogs but not for others,such as when the driver retrieves data from different DBMSs, an empty string ("") denotes those catalogs that do not have names. wszCatalogName cannot contain a string search pattern. | |
CatalogNameLength | Length of wszCatalogName. | |
wszSchemaName | String search pattern for schema names. If a driver supports schemas for some tables but not for others, such as when the driver retrieves data from different DBMSs, an empty string ("") indicates those tables that do not have schemas. | |
SchemaNameLength | Length of wszSchemaName. | |
wszTableName | String search pattern for table names. | |
TableNameLength | Length of wszTableName. | |
wszColumnName | String search pattern for column names. | |
ColumnNameLength | Length of wszColumnName. |
Return value
SQL_SUCCESS, SQL_SUCCESS_WITH_INFO, SQL_STILL_EXECUTING, SQL_ERROR, or SQL_INVALID_HANDLE.
Description
Returns the list of column names in specified tables. The driver returns this information as a result set on the specified statement handle.
Reference
- Include file
CODBCStmt.inc - Defined in AfxNova/COdbcStmt.inc:1967
- Documented in Databases/ODBC Classes/CODBCStmt Class.md
- Topic: CODBCStmt Class