While running spring boot application I got following error
2021-10-22 13:38:59.732[0;39m [33m WARN[0;39m [35m700[0;39m [2m---[0;39m [2m[ restartedMain][0;39m [36mo.h.t.s.i.ExceptionHandlerLoggedImpl [0;39m [2m:[0;39m GenerationTarget encountered exception accepting command
: Error executing DDL "alter table users_roles add constraint FKt4v0rrweyk393bdgt107vdx0x foreign key (role_id) references role (id)" via JDBC Statement
org.hibernate.tool.schema.spi.CommandAcceptanceException: Error executing DDL "alter table users_roles add constraint FKt4v0rrweyk393bdgt107vdx0x foreign key (role_id) references role (id)" via JDBC Statement
Changed spring.jpa.hibernate.ddl-auto = create-drop to update. And changed table name user to users and role to roles.
Then problem has been solved