Platforms to show: All Mac Windows Linux Cross-Platform
Back to JavaDatabaseMBS class.
JavaDatabaseMBS.connect(url as string) as JavaConnectionMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Java Database | MBS Java Plugin | 12.1 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
While getConnection calls DriverManager, this calls directly the driver.
Attempts to make a database connection to the given URL. The driver should return "null" if it realizes it is the wrong kind of driver to connect to the given URL. This will be common, as when the JDBC driver manager is asked to connect to a given URL it passes the URL to each loaded driver in turn.
The driver should throw an SQLException if it is the right driver to connect to the given URL but has trouble connecting to the database.
The java.util.Properties argument can be used to pass arbitrary string tag/value pairs as connection arguments. Normally at least "user" and "password" properties should be included in the Properties object. (the plugin passes empty Properties object)
url - the URL of the database to which to connect
Returns a Connection object that represents a connection to the URL
Throws SQLException - if a database access error occurs
JavaDatabaseMBS.Constructor(vm as JavaVMMBS, driverclass as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Java Database | MBS Java Plugin | 8.5 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
The driverclass is the name of the main class of the jdbc driver.
JavaDatabaseMBS.getConnection(url as string) as JavaConnectionMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Java Database | MBS Java Plugin | 8.5 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
The DriverManager attempts to select an appropriate driver from the set of registered JDBC drivers.
Parameters:
url - a database url of the form jdbc:subprotocol:subname
Returns:
a connection to the URL
See also:
JavaDatabaseMBS.getConnection(url as string, username as string, password as string) as JavaConnectionMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Java Database | MBS Java Plugin | 8.5 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
The DriverManager attempts to select an appropriate driver from the set of registered JDBC drivers.
Parameters:
url - a database url of the form jdbc:subprotocol:subname
user - the database user on whose behalf the connection is being made
password - the user's password
Returns:
a connection to the URL
See also:
JavaDatabaseMBS.IsDriverLoaded as Boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Java Database | MBS Java Plugin | 8.3 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
JavaDatabaseMBS.LoginTimeout as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | Java Database | MBS Java Plugin | 8.5 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
The login time limit in seconds.
(Read and Write computed property)
JavaDatabaseMBS.println(message as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | Java Database | MBS Java Plugin | 12.1 | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No | Desktop, Console & Web |
The items on this page are in the following plugins: MBS Java Plugin.