Skip to content
Advertisement

Tag: h2

H2 Db, ID NextVal

I have a sequence as: CREATE SEQUENCE OWNER_SEQ START WITH 1; I need to trigger this sequence for OWNER table’s ID column CREATE TABLE METADATA.OWNER ( OWNER_ID NUMBER NEXTVAL(…

How to fix H2 Syntax error in SQL statement?

I asked earlier today about replacing a window function because H2 does not support it. I rewrote SQL query but every time I get syntax error in the SQL query (posted below) expected “UNION, …

What is the syntax of array literal in H2 db?

I need to write an insert query where one value is an array of 3 elements. I’ve tried to do it like this: The sintax I’ve used for ‘col’ value is valid array literal in PostrgreSQL but H2 treats it as a single value of the array but not as an array with 3 elements. Table DDL: Answer Based on

Advertisement