Thanks a lot! It works!
El jueves, 23 de enero de 2020, 11:44:51 (UTC+1), Evgenij Ryazanov escribió:
>
> Hello.
>
> In general case, if you want to use multiple databases, you should use
> only standard SQL features. However, the SQL Standard does not provide any
> way to fetch the current value of the sequence. Such operation has very low
> meaning. There are other ways to fetch the generated value during insertion
> into table. For example, the JDBC has methods and parameters for generated
> keys. The SQL Standard also has own capabilities. But it looks like you use
> some weird service that can't use any sane and reliable ways.
>
> For H2 1.4.197 (this version is outdated, BTW) you can use something like
> SELECT CURRVAL(SELECT SEQUENCE_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE
> TABLE_NAME = 'acl_class' AND COLUMN_NAME = 'id')
> instead.
>
> Names of table ('acl_class') and column ('id') may need to be written in
> upper or lower case depending on way how they were created.
>
>
--
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 view this discussion on the web visit
https://groups.google.com/d/msgid/h2-database/ecad9dbd-03aa-40ad-b4c1-edf61cae3b14%40googlegroups.com.