Declaration
TnxDatabase = class(TnxDataAccessStateComponent)
Description
Implementation of a TDatabase similar component.
Methods
This method commits a pending transaction (level). If an error occurs (e.g. deadlock detected or transaction level has been marked as corrupted) the transaction is not automatically rolled back. You have to call Rollback in that case.
For more info see the nexus manual.
constructor.
Use CreateTable to create a new table with the structure defined by the given dictionary. Raises an exception on failure.
Use CreateTable to create a new table with the structure defined by the given dictionary. Returns an error code on failure.
This method deletes the table with the given name.
destructor.
EmptyTable deletes all records of the given table.
statement support
The text for this method has been generated automatically. This means that it is not documented.
???
The method returns the data dictionary of a given table. Raises an exception on failure.
The method returns the data dictionary of a given table. Returns an error code on failure.
This method returns the remaining disk space for the disk this database/alias is stored on.
This method returns the remaining disk space for the disk this database/alias is stored on.
The text for this method has been generated automatically. This means that it is not documented.
GetStoredProcNames returns a list of all stored procedures of the database.
The text for this method has been generated automatically. This means that it is not documented.
GetTableNames returns a list of all tables of the database.
The text for this method has been generated automatically. This means that it is not documented.
The text for this method has been generated automatically. This means that it is not documented.
This method starts an asynchronous packing of the table. For this purpose a new identical table is created and the records are copied over from the old one. Raises an exception on failure.
This method starts an asynchronous packing of the table. For this purpose a new identical table is created and the records are copied over from the old one. Returns an error code on failure.
The method attempts to recover records from a broken table. Recovered records are placed in a new table named TableName_Recovered. Unrecoverable records are placed in a new table named TableName_Failed.
ReindexTable starts an asynchronous re indexing of a certain index of a table. Raises an exception on failure.
ReIndexTable starts an asynchronous re indexing of a certain index of a table. Raises an exception on failure.
ReindexTableEx starts an asynchronous re indexing of a certain index of a table. Returns an error code on failure.
ReIndexTableEx starts an asynchronous re indexing of a certain index of a table. Returns an error code on failure.
RenameTable changes the name of a table.
With this method you can start an asynchronous restructure of a given table. Raises an exception on failure.
With this method you can start an asynchronous restructure of a given table. Returns an error code on failure.
Rollback rolls (as the name says) back a pending transaction (level). All changes since the last StartTransaction (or equivalent) call are lost. For more info see the nexus manual.
StartTransaction tries to start a transaction. If it fails an exception is triggered.
Start a transaction if an exclusive lock can be granted on all specified tables. If the grant fails one or more tables or an error occurs, an error code is returned.
Start a transaction if an exclusive lock can be granted on all specified tables. If the grant fails one or more tables or an error occurs, an error code is returned.
This function returns true if a table with the given name exists otherwise false.
This method marks the transaction (level) as corrupted and thus preventing it from ever being committed. For more info see the nexus manual.
Tries start a transaction (if none was started by the current TnxDatabase), returns true if a new transaction was started, false if a transaction was already started by this database instance or triggers an exception if an error occurs.
Properties
The alias name the database is connected to. Either AliasName or AliasPath must be set.
The (local server) path the database is connected to. Either AliasName or AliasPath must be set.
Returns the number of dataset instances attached to this database.
Returns the dataset with index aInx out of the list of attached dataset instances.
If a database is exclusively opened, only ONE client has access at a time.
Sets failsafe mode on or off. For more info see NexusDB manual.
Implicit is true if the database instance was create implicitly, e.g by using tnxTable directly without assigning it to a database.
Returns true if a transaction for the current database is active otherwise false.
Returns the file system path of this database.
Returns the query with index aInx out of the list of attached query instances.
Returns the number of query instances attached to the database.
With this property a database can be set to read only.
the session the database is attached to. This property must be set for the component to work properly.
Returns the number of table instances attached to the database.
Returns the table with index aInx out of the list of attached table instances.
Set the timeout for the database in ms. If -1 is specified the database inherits the value of the session it is connected to.
File