4D v16

ODBC_SQLGetInfo

Inicio

 
4D v16
ODBC_SQLGetInfo

ODBC_SQLGetInfo 


 

ODBC_SQLGetInfo ( connectionID ; tipoInfo ; infoValuePtr ) -> Resultado 
Parámetro Tipo   Descripción
connectionID  Entero largo in Connection ID
tipoInfo  Entero largo in Type of information
infoValuePtr  Puntero in Information regarding the driver and data source
Resultado  Entero largo in Returns the result of the MS ODBC API function SQLGetInfo

The ODBC_SQLGetInfo command returns general information about the driver and data source associated with a connection.

connectionID is a valid connection ID returned by ODBC_SQLAllocConnect and a connection must be established using the ODBC_SQLConnect command.

If the infoType defines the type of information regarding a driver and data source and can be one of the following values:

ConstantValueSQL_ACTIVE_CONNECTIONS0
SQL_ACTIVE_ENVIRONMENTS116
SQL_ACTIVE_STATEMENTS1
SQL_AGGREGATE_FUNCTIONS169
SQL_ALTER_DOMAIN117
SQL_ASYNC_MODE10021
SQL_BATCH_ROW_COUNT120
SQL_BATCH_SUPPORT121
SQL_BOOKMARK_PERSISTENCE82
SQL_CATALOG_LOCATION114
SQL_CATALOG_NAME_SEPARATOR41
SQL_CATALOG_TERM42
SQL_CATALOG_USAGE92
SQL_COLUMN_ALIAS87
SQL_CONCAT_NULL_BEHAVIOR22
SQL_CONVERT_BIGINT53
SQL_CONVERT_BINARY54
SQL_CONVERT_BIT55
SQL_CONVERT_CHAR56
SQL_CONVERT_DATE57
SQL_CONVERT_DECIMAL58
SQL_CONVERT_DOUBLE59
SQL_CONVERT_FLOAT60
SQL_CONVERT_FUNCTIONS48
SQL_CONVERT_GUID173
SQL_CONVERT_INTEGER61
SQL_CONVERT_INTERVAL_DAY_TIME123
SQL_CONVERT_INTERVAL_YEAR_MONTH124
SQL_CONVERT_LONGVARBINARY71
SQL_CONVERT_LONGVARCHAR62
SQL_CONVERT_NUMERIC63
SQL_CONVERT_REAL64
SQL_CONVERT_SMALLINT65
SQL_CONVERT_TIME66
SQL_CONVERT_TIMESTAMP67
SQL_CONVERT_TINYINT68
SQL_CONVERT_VARBINARY69
SQL_CONVERT_VARCHAR70
SQL_CONVERT_WCHAR122
SQL_CONVERT_WLONGVARCHAR125
SQL_CONVERT_WVARCHAR126
SQL_CORRELATION_NAME74
SQL_CREATE_ASSERTION127
SQL_CREATE_CHARACTER_SET128
SQL_CREATE_COLLATION129
SQL_CREATE_DOMAIN130
SQL_CREATE_SCHEMA131
SQL_CREATE_TABLE132
SQL_CREATE_TRANSLATION133
SQL_CREATE_VIEW134
SQL_CURSOR_ROLLBACK_BEHAVIOR24
SQL_DATETIME_LITERALS119
SQL_DDL_INDEX170
SQL_DM_VER171
SQL_DRIVER_HDBC3
SQL_DRIVER_HDESC135
SQL_DRIVER_HENV4
SQL_DRIVER_HLIB76
SQL_DRIVER_HSTMT5
SQL_DRIVER_NAME6
SQL_DRIVER_ODBC_VER77
SQL_DRIVER_VER7
SQL_DROP_ASSERTION136
SQL_DROP_CHARACTER_SET137
SQL_DROP_COLLATION138
SQL_DROP_DOMAIN139
SQL_DROP_SCHEMA140
SQL_DROP_TABLE141
SQL_DROP_TRANSLATION142
SQL_DROP_VIEW143
SQL_DYNAMIC_CURSOR_ATTRIBUTES1144
SQL_DYNAMIC_CURSOR_ATTRIBUTES2145
SQL_EXPRESSIONS_IN_ORDERBY27
SQL_FILE_USAGE84
SQL_FORWARD_ONLY_CURSOR_ATTRS1146
SQL_FORWARD_ONLY_CURSOR_ATTRS2147
SQL_GROUP_BY88
SQL_INDEX_KEYWORDS148
SQL_INFO_SCHEMA_VIEWS149
SQL_INSERT_STATEMENT172
SQL_KEYSET_CURSOR_ATTRIBUTES1150
SQL_KEYSET_CURSOR_ATTRIBUTES2151
SQL_KEYWORDS89
SQL_LIKE_ESCAPE_CLAUSE113
SQL_LOCK_TYPES78
SQL_MAX_ASYNC_CONCURRENT_STMTS10022
SQL_MAX_BINARY_LITERAL_LEN112
SQL_MAX_CHAR_LITERAL_LEN108
SQL_MAX_OWNER_NAME_LEN32
SQL_MAX_PROCEDURE_NAME_LEN33
SQL_MAX_QUALIFIER_NAME_LEN34
SQL_MAX_ROW_SIZE_INCLUDES_LONG103
SQL_MULT_RESULT_SETS36
SQL_MULTIPLE_ACTIVE_TXN37
SQL_NEED_LONG_DATA_LEN111
SQL_NON_NULLABLE_COLUMNS75
SQL_NUMERIC_FUNCTIONS49
SQL_ODBC_API_CONFORMANCE9
SQL_ODBC_INTERFACE_CONFORMANCE152
SQL_ODBC_SAG_CLI_CONFORMANCE12
SQL_ODBC_SQL_CONFORMANCE15
SQL_ODBC_SQL_OPT_IEF73
SQL_ODBC_VER10
SQL_OJ_CAPABILITIES65003
SQL_OUTER_JOINS38
SQL_OWNER_TERM39
SQL_OWNER_USAGE91
SQL_PARAM_ARRAY_ROW_COUNTS153
SQL_PARAM_ARRAY_SELECTS154
SQL_POS_OPERATIONS79
SQL_POSITIONED_STATEMENTS80
SQL_PROCEDURE_TERM40
SQL_PROCEDURES21
SQL_QUALIFIER_LOCATION114
SQL_QUALIFIER_NAME_SEPARATOR41
SQL_QUALIFIER_TERM42
SQL_QUALIFIER_USAGE92
SQL_QUOTED_IDENTIFIER_CASE93
SQL_ROW_UPDATES11
SQL_SCHEMA_TERM39
SQL_SCHEMA_USAGE91
SQL_SCROLL_OPTIONS44
SQL_SQL_CONFORMANCE118
SQL_SQL92_DATETIME_FUNCTIONS155
SQL_SQL92_FOREIGN_KEY_DELETE_RULE156
SQL_SQL92_FOREIGN_KEY_UPDATE_RULE157
SQL_SQL92_GRANT158
SQL_SQL92_NUMERIC_VALUE_FUNCTIONS159
SQL_SQL92_PREDICATES160
SQL_SQL92_RELATIONAL_JOIN_OPERATORS161
SQL_SQL92_REVOKE162
SQL_SQL92_ROW_VALUE_CONSTRUCTOR163
SQL_SQL92_STRING_FUNCTIONS164
SQL_SQL92_VALUE_EXPRESSIONS165
SQL_STANDARD_CLI_CONFORMANCE166
SQL_STATIC_CURSOR_ATTRIBUTES1167
SQL_STATIC_CURSOR_ATTRIBUTES2168
SQL_STATIC_SENSITIVITY83
SQL_STRING_FUNCTIONS50
SQL_SUBQUERIES95
SQL_SYSTEM_FUNCTIONS51
SQL_TABLE_TERM45
SQL_TIMEDATE_ADD_INTERVALS109
SQL_TIMEDATE_DIFF_INTERVALS110
SQL_TIMEDATE_FUNCTIONS52
SQL_UNION96
SQL_UNION_STATEMENT96

The infoValuePtr argument retrieves the information regarding the driver and data source defined by infoType. The value returned depends on the type of information passed to infoType.

For more information, please see the SQLGetInfo function in the MS ODBC API Reference at http://msdn.microsoft.com/en-us/library/ms711681(VS.85).aspx.

SQL_SUCCESS, SQL_SUCCESS_WITH_INFO, SQL_ERROR, or SQL_INVALID_HANDLE.

Ejemplo  

The following method connects you to a data source and then retrieves information about the driver to find out the level of asynchronous support in the driver:

 $result:=ODBC_SQLSetEnvAttr(SQL_ATTR_ODBC_VERSION;3)
 $result:=ODBC_SQLAllocConnect($connectionID)
 $result:=ODBC_SQLConnect($connectionID;"oracle4d";"Admin";"admin1")
 $result:=ODBC_SQLGetInfo($connectionID;10021;->asyncType) `SQL_ASYNC_MODE

 
PROPIEDADES 

Producto: 4D
Tema: ODBC_Information
Número 16987

 
HISTORIA 

Creado por: 4D ODBC Pro 2004

 
ARTICLE USAGE

4D ODBC Pro ( 4D v16)