A Database object contains the properties for a logical database in the data dictionary.
Stonefield Query uses the concept of a "main" database for an application. The main database is the one the user can change data sources for. All other databases are assumed to be related to the main one in that selecting the data source for the main one somehow determines how the data source for the others is selected.
For example, imagine an accounting application that has two databases: a system database that contains application-specific data, and a company-specific database containing the accounting information for the company. The user may have different databases for different companies, so they can change data sources to select the appropriate database for the desired company. However, there is only one system database. In this case, the company-specific database is considered to be the main one, since that's the one the user can select different data sources for.
|Active||Boolean||True (the default) if the database is available to be queried on. Set this to False if the database should be disabled, such as if the database is optional and isn't available to this particular user. This setting is ignored for the main database.|
|Connected||Boolean||True if the database is currently connected to a data source.|
|CurrentDataSource||Object||A reference to the current DataSource object for this database.|
|DatabaseName||String||The name of the database.|
|DataSourceName||String||The name of the current data source for this database.|
|DataSources||Object||A reference to the DataSources collection for this database.|
|Description||String||The descriptive name for the database.|
|ErrorMessage||String||The text of any error that occurs.|
|MainDatabase||Boolean||True if this is the main database for the application.|
|NameDelimiters||String||The delimiters used for names.|
|Quiet||Boolean||True to not display error messages; the default is False.|
|ExecuteSQLStatement||Executes a SQL statement against the current data source for this database.|
|OpenDataSource||Opens the specified data source for this database.|
See alsoDatabases Collection | DataSource Object | DataSources Collection
© Stonefield Software Inc., 2018 • Updated: 08/25/16
Comment or report problem with topic