[h2] Re: What is the latest stable release?

2019-05-03 Thread Evgenij Ryazanov
Hello. If your database is in PageStore format you need to export it to SQL script with 1.4.196, create a new database with a new version and populate it with this script due to issue #1247. https://github.com/h2database/h2database/issues/1247

Re: [h2] Re: Recent drops in performance

2019-05-03 Thread Evgenij Ryazanov
Hello. Your cte.sql contains runscript from 'init.sql'; Do you measure performance of the query or performance of database population with data? I don't see any noticeable differences in execution time of the query itself between 1.4.196 and 1.4.199 in both PageStore and MVStore databases

Re: [h2] What is the latest stable release?

2019-05-03 Thread Noel Grandin
We don't really have a stable vs bleeding edge anymore, the 1.4 series are all pretty stable. What I would suggest you do is (*) take a look at the commits since the last release and the comments on the mailing list, and decide if any of them constitute show stoppers for you (*) run your unit

[h2] What is the latest stable release?

2019-05-03 Thread Rich B
Hi there Just wondering what the latest stable release is? http://www.h2database.com/html/download.html ^ Says "Last Stable" is 1.4.197 (2018-03-18) - seems a long time ago. I don't need bleeding edge, but I want the best new one on from 1.4.196 which I'm currently using. Cheers Rich -- You

Re: [h2] Re: Recent drops in performance

2019-05-03 Thread Christian MICHON
Hi, I moved away from memory database to pure embedded database, using pagestore format. I stick to CTE, as it was supported for the releases used inside comparison scope, and CTE is slowish to allow comparison of graphs. DDL and DDQ were too fast for the graphs to be differentiated. I've

[h2] Re: Removal of SELECT_FOR_UPDATE_MVCC 1.4.197 -> 1.4.199

2019-05-03 Thread Nicklas Wallgren
Thanks, I'll consider the sub query solution. // Nicklas It's actual safe enough for my user case using the MySQL InnoDB engine, and default transaction isolation level. CREATE TABLE report S1 begin; S2 begin; S1 select coalesce(max(r.sequence) + 1, 1) from reports r where

[h2] Re: Removal of SELECT_FOR_UPDATE_MVCC 1.4.197 -> 1.4.199

2019-05-03 Thread Evgenij Ryazanov
BTW, you can't lock rows that don't exist, so if there were no rows with the specific report_id your select will be unsafe (unless you use some additional locking in this corner case). -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To

[h2] Re: Removal of SELECT_FOR_UPDATE_MVCC 1.4.197 -> 1.4.199

2019-05-03 Thread Evgenij Ryazanov
It's not related in any way with compatibility modes. Perhaps you can lock the rows in a subquery. select coalesce(max(sequence) + 1, 1) from (select sequence from r where r.report_id = ? for update) -- You received this message because you are subscribed to the Google Groups "H2 Database"

[h2] Re: Removal of SELECT_FOR_UPDATE_MVCC 1.4.197 -> 1.4.199

2019-05-03 Thread Nicklas Wallgren
Alright, that is unfortunately. We will have to stick to *1.4.197*. And it's not possible to override the behaviour using compability modes? For example *MODE=MYSQL* Yes, we need to lock all entries containing the `report_id` inorder to ensure the number serie. Example table report_id,

[h2] Re: Removal of SELECT_FOR_UPDATE_MVCC 1.4.197 -> 1.4.199

2019-05-03 Thread Evgenij Ryazanov
Hello. SELECT_FOR_UPDATE_MVCC was useless after other changes in H2. The exception that you got describes the situation pretty clear: you can't use FOR UPDATE clause when you use aggregates (or distinct). Grouped queries don't return the original rows, FOR UPDATE is disallowed in such queries

[h2] Changed behaviour of FOR UPDATE 1.4.197 -> 1.4.199

2019-05-03 Thread Nicklas Wallgren
Hey, I have been using `SELECT_FOR_UPDATE_MVCC=FALSE` in order to use `FOR UPDATE` in my queries. In the latest update of H2 (1.4.199) I encountered a new type of error. *The error message* FOR UPDATE is not allowed in DISTINCT or grouped select; SQL statement: *The actual query* select

[h2] Removal of SELECT_FOR_UPDATE_MVCC 1.4.197 -> 1.4.199

2019-05-03 Thread Nicklas Wallgren
Hey, I have encountered an new issue with "FOR UPDATE"-statements in the latest version of H2 *1.4.199*. It seems like the "SELECT_FOR_UPDATE_MVCC" option has been removed. Unsupported connection setting "SELECT_FOR_UPDATE_MVCC" [90113-199] The following query was supported in *1.4.197* select