This is a problem with update-with-from functionality, which is supported in PostgreSQL mode. Try the following: open database in PostgreSQL mode, e.g. java -cp h2-2.1.214.jar org.h2.tools.Shell -url "jdbc:h2:./test;MODE=PostgreSQL" -user sa, then do the following:
create table rec1 (id1 integer, id2 integer, val integer, primary key (id1, id2));
update rec1 r set r.val = 1 from (values (1)) v (a) where r.id1 = v.a;
The following error is printed: Error: org.h2.jdbc.JdbcSQLIntegrityConstraintViolationException: NULL not allowed for column "V.A";
There is no reason to have such error. Or, is it some?