| Hi Kai. Are you using the org.hibernate.dialect.H2Dialect dialect? Because usually with this dialect the constraints are add added in the subsequent alter table rows. Such as: code create table Client ( id integer generated by default as identity, name varchar(255), primary key (id) ) create table User_ ( id integer generated by default as identity, credentials_id bigint not null, functionrights_id bigint not null, name varchar(255) not null, client_id integer not null, primary key (id) ) alter table User_ add constraint UKk72lpbblgi5qbf010ipy3ec4o unique (client_id, name) alter table User_ add constraint UK_icj8srimshmevc7ym1xbfpb6w unique (credentials_id) alter table User_ add constraint UK_k6xve0c683wrflmclha4qby86 unique (functionrights_id) alter table User_ add constraint FKl461fnjx3swni7l0aiyi8rd0k foreign key (client_id) references Client code |