dotConnect for MySQL Documentation
Devart.Data.MySql Namespace / MySqlConnection Class / Database Property

In This Topic
Database Property (MySqlConnection)
In This Topic
Gets or sets the name of the current database or the database to be used once a connection is open.
Syntax
'Declaration
 
Public Shadows Property Database As String
 

Property Value

The name of the current database or the name of the database to be used once a connection is open. The default value is an empty string ("").
Remarks

If the query contains no reference to database to which a table belongs, an attempt is made to find the table in database, which name is specified in Database property. If the value of the property is empty, you must include in a query name of a database for every table you use.

Assigning a value to this property reopens the current connection.

See Also