I have an application which starts a TCP Server using the Server class. Once the server is started the application then tries to establish the connection (the database might not exists) using
Server h2server = Server.createTcpServer(new String[]{"-tcpAllowOthers", "-tcpPort", "9090", "-baseDir", "somepath"});
h2server = h2server.start();
Connection con = DriverManager.getConnection("jdbc:h2:tcp://localhost:9090/test;mvcc=true;autocommit=off");
immediately after this when I issue the command "con.getAutoCommit()" always returns a true.
This also happens when using the connection string as follows and not starting the server before hand:
DriverManager.getConnection("jdbc:h2:tcp://localhost/~/test;mvcc=true;autocommit=off");
While "con.getAutoCommit()" returns a false when using the connection string with "jdbc:h2:file:".
Am I doing something wrong or is the AutoCommit=off not supported in Server Mode?