Module: DB Interface Module Group: Database Classes
Does not inherit
#include <rw/db/envhandl.h> RWDBDatabase::connect(false); RWDBDatabase myDbase = RWDBManager::database( ... ); RWDBEnvironmentHandle* envHandle = myDbase.environmentHandle();
RWDBEnvironmentHandle is a base class from which a family of implementation specific classes is derived. RWDBDatabase::environmentHandle() returns a pointer to this base class. To set connect time configuration parameters or configuration properties for an entire application, the application downcasts this pointer to the appropriate type, and uses its implementation-specific features. The configuration parameters that an application can set vary widely among vendors. Please see the guide for your Access Module.
NOTE -- You must link the appropriate DB Access Module directly with your application in order to downcast an instance of RWDBEnvironmentHandle to a particular database type. Using this class reduces the portability of your application.
None.
RWDBEnvironmentHandle();
Constructs an empty RWDBEnvironmentHandle. This constructor is provided as a convenience. Usable RWDBEnvironmentHandles should be produced by RWDBDatabases. See the guide for your Access Module for specific details on how to use the methods of class RWDBEnvironmentHandle.
bool cacheResultSchemas() const;
Returns the state of the flag that controls whether to install and use result schema caching.
bool cacheResultSchemas(bool value);
Enables or disables result schema caching. Result schema caching can improve performance, but should not be used when database schemas are dynamic. See Section 9.5, "Result Schema Caching," in the DB Interface Module User's Guide.
virtual bool foreignKeysFromView();
Returns the state of the flag that controls whether to install and use a stored procedure with RWDBTable::foreignKeys().
virtual bool foreignKeysFromView(bool value);
When value is true, enables a higher-performance version of RWDBTable::foreignKeys(), in access modules where this version exists. The higher-performance version is implemented by installing a stored procedure in the database for quicker system table queries. Passing false enables the standard version of RWDBTable::foreignKeys(). Check your access module guide for details on this possible performance enhancement.
size_t maxCachedResultSets() const;
Returns the maximum number of result sets being cached from execution of an SQL query. Result sets are cached by SourcePro DB when using a Data Manipulation class.
size_t maxCachedResultSets(size_t value);
Limits the number of result sets that are cached from execution of an SQL query to 'value'. Caching result sets improves performance for subsequent executions of the same SQL, but if the SQL returns a large number of result sets, or some number of very large ones, memory usage can become an issue. The result sets are cached by SourcePro DB when using a Data Manipulation class. The default value is 100.
© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.