Click or drag to resize

IDatabase Methods

The IDatabase type exposes the following members.

Methods
  NameDescription
Public methodBeginTransaction
Public methodClone
Make a clone of the current database.
Public methodClose
The Close method closes the underlying Connection object and rolls back any pending transactions. It then releases the connection to the connection pool, or closes the connection if connection pooling is disabled.
Public methodCommitTransaction
Public methodCode exampleDBCount(String, String, String)
Returns the number of items in the specified column and table using the SQL WHERE clause supplied. Note: For improved performance use DBExists(String, String) when possible.
Public methodCode exampleDBCount(String, String, String, DataFuncOptions, String)
Returns the number of items in the specified column and table using the SQL WHERE clause supplied. Note: For improved performance use DBExists(String, String, DataFuncOptions, String) when possible.
Public methodCode exampleDBCount(String, String, String, DataFuncOptions, String, Int32)
Returns the number of items in the specified column and table using the SQL WHERE clause supplied. Note: For improved performance use DBExists(String, String, DataFuncOptions, String) when possible.
Public methodCode exampleDBCountCache
Returns the number of items in the specified column and table using the SQL WHERE clause supplied. Note: For improved performance use DBExistsCache(String, String, DataFuncOptions, String) when possible. DBCountCache is an enhancement to the existing DBCount function. Ultimately we still use the same DBCount mechanism to retrieve the required value but the result is cached to Thread Local Storage. Subsequent requests to lookup the same count (using the SAME SQL) will pull that value from the thread cache rather than hitting the database.
Public methodDBExists(String, String)
Determines if a particular record exists. For better performance and clarity, use this instead of DBCount(String, String, String) to determine if a record or records exist.
Public methodDBExists(String, String, DataFuncOptions)
Determines if a particular record exists. For better performance and clarity, use this instead of DBCount(String, String, String, DataFuncOptions, String) to determine if a record or records exist.
Public methodDBExists(String, String, DataFuncOptions, String)
Determines if a particular record exists. For better performance and clarity, use this instead of DBCount(String, String, String, DataFuncOptions, String) to determine if a record or records exist.
Public methodDBExistsCache
Determines if a particular record exists. For better performance and clarity, use this instead of DBCount(String, String, String, DataFuncOptions, String) to determine if a record or records exist. DBExistsCache is an enhancement to the existing DBExists function. Ultimately we still use the same DBExists mechanism to retrieve the required value but the result is cached to Thread Local Storage. Subsequent requests to check existence of the same value (using the SAME SQL) will pull that value from the thread cache rather than hitting the database.
Public methodCode exampleDBLookup(String, String, String)
You can use the DBLookup function to get the value of a particular column from a specified set of records (a domain).
Public methodCode exampleDBLookup(String, String, String, DataFuncOptions, String)
You can use the DBLookup function to get the value of a particular column from a specified set of records (a domain).
Public methodCode exampleDBLookup(String, String, String, DataFuncOptions, String, String)
You can use the DBLookup function to get the value of a particular column from a specified set of records (a domain).
Public methodCode exampleDBLookupCache
DBLookupCache is an enhancement to the existing DBLookup function. Ultimately we still use the same DBLookup mechanism to retrieve the required value but the result is cached to Thread Local Storage. Subsequent requests to lookup the same value (using the SAME SQL) will pull that value from the thread cache rather than hitting the database.
Public methodExec
The Exec method provides extended functionality.
(Inherited from IEAPBase.)
Public methodExecute(String)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, String)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, ExecuteOptions, String)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, String, Int32)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, ExecuteOptions, String, String)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, ExecuteOptions, String, String, Int32)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, ExecuteOptions, String, String, String)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, ExecuteOptions, String, String, String, Int32)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecute(String, ExecuteOptions, String, String, String, Int32, Int32)
You can use the Execute method to perform catalog operations (for example, creating database objects such as tables), or to change the data in a database without using a DataSet by executing UPDATE, INSERT, or DELETE statements.

For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Public methodExecuteScalar(String, String)
Execute a scalar SQL statement (a statement that returns a single item).
Public methodExecuteScalar(String, String, Int32)
Execute a scalar SQL statement (a statement that returns a single item).
Public methodExecuteThroughAdapter(String, String, Hashtable, ExecuteThroughAdapterAttrs)
Executes an insert, update or delete through IDbDataAdapter, Dataset, DataTable, DataRow
Public methodExecuteThroughAdapter(String, String, Hashtable, ExecuteThroughAdapterAttrs, String)
Executes an insert, update or delete through IDbDataAdapter, Dataset, DataTable, DataRow
Public methodFillStringCollection
Fill a StringCollection with the contents of the first column in the provided query. Note that each value will be converted to a string.
Public methodFireAndForget(String, ExecuteOptions, String)
Execute the specified SQL asynchronously. The SQL execution is spun off to the thread pool to be executed when a thread becomes available, and control is returned to the caller immediately. Note that there is no way to get the result, or success/failure of the execution except to query if from the database.
Public methodFireAndForget(String, ExecuteOptions, String, FireAndForgetOptions)
Execute the specified SQL asynchronously. The SQL execution is spun off to the thread pool to be executed when a thread becomes available, and control is returned to the caller immediately. Note that there is no way to get the result, or success/failure of the execution except to query if from the database.
Public methodGetSchemaInfo(String)
Gets a SchemaInfoCollection describing the specified table or view with SchemaInfo objects for each column. Note that schema information is cached on demand and per-DatabaseID. If the specified table does not exist then an empty (but not null) SchemaInfoCollection will be returned and you can test ObjectExists to determine whether or not the object exists. You can use GetSchemaInfo(String, SchemaInfoType) for various schema object, including tables and views.
Public methodGetSchemaInfo(String, SchemaInfoType)
Gets a SchemaInfoCollection describing the specified database object with SchemaInfo objects for each column or input parameter. Note that schema information is cached on demand and per-DatabaseID. If the specified table does not exist then an empty (but not null) SchemaInfoCollection will be returned and you can test ObjectExists to determine whether or not the object exists.
Public methodHibernate
Public methodLoadFile
Load the specified file data into a memory stream. If no records are found then the stream object will be created, but will be empty. If multiple records are found then data will be loaded from the first record only.
Public methodLoadProperties
Loads the database Properties from the repository database.
Public methodOpen
Opens the connection to the underlying data source.
Public methodOpen(IAppContext, String)
Opens the connection to the underlying data source.
Public methodOpen(IAppContext, String, DatabaseOpenOptions)
Opens the connection to the underlying data source.
Public methodOpenCachedTable(String, String)
Opens a new DataSet and returns the first DataTable, retrieving it from the cache if it is cached. If the object is not cached, it is opened from the datasource and added to the global cache.
Public methodOpenCachedTable(String, String, String)
Opens a new DataSet and returns the first DataTable, retrieving it from the cache if it is cached. If the object is not cached, it is opened from the datasource and added to the global cache.
Public methodOpenCachedTable(String, String, String, Boolean)
Opens a new DataSet and returns the first DataTable, retrieving it from the cache if it is cached. If the object is not cached, it is opened from the datasource and added to the global cache.
Public methodOpenDataReader(String)
Opens a recordset using the internal connection and default options.
Public methodOpenDataReader(String, String)
Opens a recordset using the internal connection and default options.
Public methodOpenDataReader(String, DataFuncOptions, String)
Opens a recordset using the internal connection.
Public methodOpenDataReader(String, String, Int32)
Opens a recordset using the internal connection.
Public methodOpenDataReader(String, IDbConnection, DataFuncOptions, String)
Opens a recordset using the specified connection.
Public methodOpenDataReader(String, IDbConnection, DataFuncOptions, String, String)
Opens a recordset using the specified connection.
Public methodOpenDataReader(String, IDbConnection, DataFuncOptions, String, String, Int32)
Opens a recordset using the specified connection.
Public methodOpenDataset(String)
Opens one or more tables or views.
Public methodOpenDataset(String, String)
Opens one or more tables or views.
Public methodOpenDataset(String, String, Int32)
Opens one or more tables or views.
Public methodOpenHashtable
Opens a 2 column statement on the encapsulated connection and returns the results as a hashtable. Note that a hashtable is ALWAYS returned even if no records were found (in which case it will be empty).
Public methodOpenTable(String)
Opens a new DataSet and returns the first DataTable. If caching is appropriate use OpenCachedTable(String, String) for improved performace.
Public methodOpenTable(String, String)
Opens a new DataSet and returns the first DataTable. If caching is appropriate use OpenCachedTable(String, String, String) for improved performace.
Public methodOpenTable(String, String, Int32)
Opens a new DataSet and returns the first DataTable. If caching is appropriate use OpenCachedTable(String, String, String) for improved performace.
Public methodResolveEmbeddedFunction
Resolve a SQL string for embedded functions. See EmbeddedParser for more information on embedded functions.
Public methodRollbackTransaction
Public methodTableSpace
Gets the space used by the specified table. Currently this method is only supported for SQL-Server where the sp_spaceused stored procedure is used. For non-supported DBMS's, an empty (non-null) space descriptor is returned. At this time, an exception is thrown if the table does not exist, but this behaviour may change in the future and is not guaranteed.
Public methodWakeUp
Top
See Also