Hello.
No, it's not a TODO. It's a comment why the conditions below are necessary.
Nested DML commands weren't not supported.
However, the current implementation is entirely different and
hypothetically it should work in your use case.
You can build H2 from the sources and test it with your
Autoincrement primary key column in H2 causes allocation of new value
during execution of INSERT. Normally these values should be returned from
Statement.getGeneratedKeys(). Somehow this API works fine with H2.196. In
latest code some major refactoring was done using new class in H2 -