Language Reference Guide : System Classes : StringObject Class : DBHandle Attribute
 
Share this page          
DBHandle Attribute
Data Type: varchar(76)
4GL Access: RW
The DBHandle attribute contains a DBHandle, which points to text stored in a database table.
The DBHandle is an internal ID. OpenROAD constructs the DBHandle automatically when you use the InsertIntoDB method on the StringObject to store its associated text in the database.
If you set this attribute, OpenROAD automatically reads the text from the database, associates the text with the specified string object, and displays the text if the string object is currently displayed. You can also use this attribute in select statements.
Do not set this attribute with autocommit turned on.
If you set this attribute to an empty or null string, OpenROAD clears the existing text. If you set this attribute to a DBHandle that is invalid or that represents text that does not exist, OpenROAD generates an error message and clears the text.
Whenever your program sets a DBHandle, you are working directly with the database, initiating a database transaction if none is open at the time. You must explicitly commit the work performed. For more information about DBHandles and database transactions, see the Programming Guide.