Re: RuntimeException in a Select max() query

2012-10-02 Thread Noel Grandin
Turn off MVCC. Thomas, perhaps the MVCC option should be disabled, since it keeps causing problems ? On 2012-10-01 10:02, Ignasi Marimon-Clos i Sunyol wrote: -- You received this message because you are subscribed to the Google Groups H2 Database group. To post to this group, send email to

Identity Column Jumps Randomly

2012-10-02 Thread Jashveer Anand
Hi, H2 is very fast, and really fantastic to work. Recently, I migrated to 1.3.168 and changed all my auto_increment columns to Identity. I am using scope_identity() to get the primary key created and also have trigger for that table. While inserting, many times, the identity columns jumps by

H2 In-Memory Database Cache and H2 Performance vs. MySQL Performance

2012-10-02 Thread snookerms
Hello, I'm using a H2 In-Memory Database with 250.000 DataSets (Rows of data). I'm running a SQL-Query the first time it takes 1540ms. The Second time it take 749ms and the third time 503ms and so on. A other Query need the first time 251ms and after that 6ms per run. The only explanation I

IDENTITY COLUMN JUMPING BY 32

2012-10-02 Thread Jashveer Anand
Hi all, H2 is very fast and fantastic to work. I recently upgraded H2 1.3.168. And converted all my auto_increment columns to Identity(). I have tables with identity column and I am using scope_identity() to get the value, since I am using triggers. Some occasions, the identity column

Re: IDENTITY COLUMN JUMPING BY 32

2012-10-02 Thread Ryan How
Hi, I'm pretty sure the reason is because H2 caches the next 32 identity values, so if you close the database and open it again, then it will skip those values. There isn't a guarantee that it always increment by 1. Pretty sure if you roll back transactions then it skips the value also. I'm

Re: H2 In-Memory Database Cache and H2 Performance vs. MySQL Performance

2012-10-02 Thread Ryan How
Maybe this is due to the JIT compiler optimising it? On 2/10/2012 6:31 PM, snookerms wrote: I'm running a SQL-Query the first time it takes 1540ms. The Second time it take 749ms and the third time 503ms and so on. -- You received this message because you are subscribed to the Google Groups

Using OR in where clause does not use index

2012-10-02 Thread BrianR
If column a is index and running a query of SELECT * FROM tableFoo WHERE a = 'value' OR a LIKE 'value2' does not use the index on a. I also noticed the following query does not use an index SELECT * FROM tableFoo WHERE a = 'value' OR 1=1 This may be by design but probably should be

Re: closing old connections from h2 console

2012-10-02 Thread Adam McMahon
Thomas, Thanks for the feedback... -Adam On Sunday, September 30, 2012 12:47:35 PM UTC-4, Thomas Mueller wrote: Hi, The db_close_delay is a delay and should do what you are looking for. For example db_close_delay=10 will close the database if there are no open connections for 10