Sorry for the late response, I was down with Covid. That makes sense, thanks! I would have to look into user defined functions but as long as they can make use of connection-specific state (the normal CURRENT_TIMESTAMP would have to be used simultaneously on all connections except the one performing the redo) this should work nicely.
I agree that this should be handled in the application layer but I have quite some legacy code that lacks the abstraction layers of the current code base that allows me to handle this there. This trick can help me add transparent log/redo functionality to the older parts of our application. On Thursday, 21 July 2022 at 15:56:26 UTC+2 Evgenij Ryazanov wrote: > Hello! > > You can only add ;BUILTIN_ALIAS_OVERRIDE=TRUE to JDBC URL and create an > own user-defined function with that name (CREATE ALIAS > "CURRENT_TIMESTAMP" …): > https://h2database.com/html/commands.html#create_alias > > But usually it is better to move that logic from database level to Java > persistence level or application level. > -- 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/20d3c247-1fa2-45e5-a3f3-38a97d2aab77n%40googlegroups.com.
