I have the following sql migration, that doesn't work with h2. If I remove the following SQL - everything works fine. How can i solve it?
SQL State : 42001
Error Code : 42001
Message : Syntax error in SQL statement "CREATE TABLE USER_AUTHORITY
(
USER_AUTHORITY_ID BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY,
USER_ID BIGINT REFERENCES USR (USER_ID) NOT NULL[*],
AUTHORITY_ID BIGINT REFERENCES AUTHORITY (AUTHORITY_ID) NOT NULL,
OPERATION VARCHAR(2) NOT NULL,
CREATION_DATETIME TIMESTAMP WITH TIME ZONE NOT NULL,
MODIFYING_DATETIME TIMESTAMP WITH TIME ZONE NOT NULL
)"; expected "DEFERRABLE";
Location : db/migration/V1__Schema.sql (/home/v/IdeaProjects/stocky/user-service/build/resources/main/db/migration/V1__Schema.sql)
Line : 29
Statement : create table user_authority