' Both cause exceptions, setCatalog not found.
Dim jo as JavaObject = Main.dbpool
jo.RunMethod("setCatalog",Array As Object("newdb"))
con=Main.dbpool.GetConnection
Dim jo as JavaObject = con
jo.RunMethod("setCatalog",Array As Object("newdb"))
con = Main.dbpool.GetConnection
con.ExecNonQuery2("USE newdb")
con.ExecNonQuery("USE `newdb`")
Main.dbpool.Initialize("org.mariadb.jdbc.Driver", "jdbc:mariadb://127.0.0.1:3306/?characterEncoding=utf8", "myusername", "mypassword")
Sub GetNewSQLConnection(DatabaseName As String) as SQL
Dim SQLObject as SQL = Main.dbpool.GetConnection
SQLObject.ExecNonQuery("USE `" & DatabaseName & "`")
Return SQLObject
End Sub