The following tables list the members exposed by DatabaseObject.
| Name | Description | |
|---|---|---|
![]() | DatabaseObject Constructor | Overloaded. DatabaseObject Default constructor for this class. |
| Name | Description | |
|---|---|---|
![]() | AffectedRecords | AffectedRecords Holds an Int32 value which can be used to hold the number of records that are either returned or affected by a query. This can be very useful in cases where a count of returned rows is needed. |
![]() | ConnectionString | ConnectionString Holds the value for connection String used to make a connection to the target database. This property is automatically initialized with the value from the application configuration settings. The value of ConnectionStringConfigName is used to look for the connection String from the application settings (AppSettings/Keys in Framework 1.1 and ConnectionSettings/Connections in Framework 2.0).. This property can also be manually set to point the library to a database other than the default. This will be useful if you need the library to connect to multiple database. |
![]() | ConnectionStringConfigName | ConnectionStringConfigName Set this property to change the name of the connection String. By default the library looks for a "database" connection String (AppSettings/Keys in Framework 1.1 and ConnectionStrings in Framework 2.0). This property should be modified before the database connection is initiated. |
![]() | DatabaseTypeConfigName | DatabaseTypeConfigName Set this property to change the name of the AppSettings key that contains the database type information. By default the library looks for a "database_type" AppSettings key. |
![]() | DBType | DBType Specifies the uderlying database server that will be used by this library. |
![]() | ErrorString | ErrorString Holds a String value. This value is used to store the errors that were encountered while working with any of the database objects. |
| Name | Description | |||||
|---|---|---|---|---|---|---|
![]() | SetDatabaseType | SetDatabaseType Takes a String as the parameter and sets the DBType property with the type of database to which this object will be connecting. Parameters:
|
| Name | Description | |
|---|---|---|
![]() | EnsureConnectionString | EnsureConnectionString Checks the ConnectionString property and if it is nont set, it will try to get the Configuration / AppSettings / key (1.1 Framework) or Configuration / ConnectionStrings / key (2.0 Framework) that defines the database connection String. Calling this method is not needed in normal scenarios. This will be needed only if you are changing the ConnectionStringConfigName property through the code and would want to ensure that the new value is loaded from the configuration file and the ConnectionString property is updated accordingly. If you are calling EnsureDatabaseType method as well then you don't need to do that as EnsureDatabaseType is called by the EnsureConnectionString. |
![]() | EnsureDatabaseType | EnsureDatabaseType Checks the DBType property and if it is set to None, it will try to get the Configuration / AppSettings / key that defines the DBType. Calling this method is not needed in normal scenarios. This will be needed only if you are changing the DatabaseTypeConfigName property through the code and would want to ensure that the new value is loaded from the configuration file and the DBType property is updated accordingly. If you are calling EnsureConnectionString method as well then you don't need to call EnsureDatabaseType as it is called by the EnsureConnectionString. |



