SQLConnection Class |
Namespace: VO
The SQLConnection type exposes the following members.
Name | Description | |
---|---|---|
SQLConnection |
Construct an SQL connection.
|
Name | Description | |
---|---|---|
AccessMode |
A constant representing the SQL connection's access mode.
| |
ActiveStmts |
List of active statements for the connection
| |
Connected |
A logical value representing whether the SQL connection object is connected.
| |
ConnectString |
A string representing the connection parameters (for example, "DSN=<Source>;UID=<UserID>;PWD=<Authorization>"). This string is initialized during the SQLConnection:Connect() or SQLConnection:DriverConnect() methods.
| |
ConnHandle |
A long integer representing the connection handle.
| |
DataSource |
A string representing the ODBC data source name.
| |
EnvHandle |
A long integer representing the environment handle.
| |
ErrInfo | SqlErrorInfo object for the last error occured for the connection or NIL. | |
HyperLabel |
The hyperlabel of the connection containing the name of the data source, or NIL, if there is no data source name.
| |
IdentifierQuoteChar |
A string used to surround a delimited identifier for this connection.
| |
IsolationOption |
A constant representing the isolation level of the SQL connection.
| |
ODBCCursors |
A constant representing the cursor type for the SQL connection.
| |
Password |
A string containing the ODBC password (authorization string).
| |
PositionOps |
A logical value representing whether the driver supports positioned operations
| |
ScrollConcurrency |
A constant representing the concurrency level of the SQL connection.
| |
ScrollCsr |
A logical value representing whether the driver supports scrollable cursors.
| |
Status |
A hyperlabel of the SQLConnection object containing the error message, or NULL_OBJECT, if no error has occurred.
| |
UserID |
A string representing the ODBC user ID.
|
Name | Description | |
---|---|---|
BeginTransaction | ||
Commit | ||
Connect |
Connect a user to an ODBC data source.
| |
Disconnect |
Disconnect the current user from an ODBC data source.
| |
DriverConnect |
Display a dialog box prompting for a source; after a source is selected, displays the driver's connection dialog box; then connects to the selected data source.
| |
EndTransaction | ||
GetConnectOption |
Return current setting for a connection option.
| |
Info |
Return current setting for connection information.
| |
isFunction |
Determine whether an ODBC function is supported by the driver.
| |
Reconnect |
Disconnect the current user from a data source; if connected; then, connect.
| |
Rollback | ||
SetConnectOption |
Set the value of a connection option.
|
1FUNCTION Start() 2LOCAL oConn AS SQLConnection 3oConn := SQLConnection{} 4// SAMPLE source has been set up to connect to // WATCOM 5oConn:Connect("sample","dba","sql") 6// Check for errors 7IF IsNil(oConn:ErrInfo) 8oConn:Disconnect() 9ELSE 10oConn:ErrInfo:ShowErrorMsg() 11ENDIF