Hi, Possibly you are using a quite old H2 server in combination with a new H2 client. In theory that should work without problems, but maybe in this case there is an incompatibility.
I would check which versions of H2 you are using. Regards, Thomas On Thursday, November 27, 2014, 'Bruce Martin' via H2 Database < [email protected]> wrote: > I was wondering if you could help me with this issues h2 server mode > > > connection.setAutoCommit(false); > > // Run some SQL > > connection.setAutoCommit(true); // Connection problem > > > The code does work with > > h2 embedded mode > HSQLDB (only tried 1.* series) > DERBY > SqlLite > > While I could change the code, this may introduce problems with other DB's > > This issue has always put me off using H2 as the main DB in my project. > > *OS:* Windows 8.1 (but also occurred with earlier versions of Windows) > *H2 Version:* 1.4.182, 1.3.176 (+ earlier versions) > > > *Note: *These errors occurred when running under an old *Marthon *Gui > test runner. Marathon does update > the swing classes (to its own version of Swing). > > > Stack Trace (when DB on USB Stick): > > org.h2.jdbc.JdbcSQLException: Connection is broken: "unexpected status > 257" [90067-182] > at > org.h2.message.DbException.getJdbcSQLException(DbException.java:345) > at org.h2.message.DbException.get(DbException.java:179) > at org.h2.message.DbException.get(DbException.java:155) > at org.h2.engine.SessionRemote.done(SessionRemote.java:637) > at > org.h2.engine.SessionRemote.setAutoCommitSend(SessionRemote.java:251) > > at > org.h2.engine.SessionRemote.setAutoCommit(SessionRemote.java:226) > at > org.h2.jdbc.JdbcConnection.setAutoCommit(JdbcConnection.java:432) > at > net.sf.RecordEditor.utils.jdbc.AbsDB.setAutoCommit(AbsDB.java:884) > at > net.sf.RecordEditor.utils.jdbc.AbsDBTableModel.updateDB(AbsDBTableModel.java:236) > at > net.sf.RecordEditor.layoutEd.panels.RecordPnl.saveRecordDetails(RecordPnl.java:747) > > > When the DB is on HardDisk I got a status of 21 instead of 257: > > org.h2.jdbc.JdbcSQLException: Connection is broken: "unexpected status 21" > [90067-182] > at > org.h2.message.DbException.getJdbcSQLException(DbException.java:345) > at org.h2.message.DbException.get(DbException.java:179) > at org.h2.message.DbException.get(DbException.java:155) > at org.h2.engine.SessionRemote.done(SessionRemote.java:637) > at > org.h2.engine.SessionRemote.setAutoCommitSend(SessionRemote.java:251) > > at > org.h2.engine.SessionRemote.setAutoCommit(SessionRemote.java:226) > at > org.h2.jdbc.JdbcConnection.setAutoCommit(JdbcConnection.java:432) > at > net.sf.RecordEditor.utils.jdbc.AbsDB.setAutoCommit(AbsDB.java:884) > > -- > You received this message because you are subscribed to the Google Groups > "H2 Database" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] > <javascript:_e(%7B%7D,'cvml','h2-database%[email protected]');> > . > To post to this group, send email to [email protected] > <javascript:_e(%7B%7D,'cvml','[email protected]');>. > Visit this group at http://groups.google.com/group/h2-database. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/h2-database. For more options, visit https://groups.google.com/d/optout.
