@Entity
@Table(name = "\"user\"")
@SoftDelete(columnName = "is_deleted")
public class UserEntity {
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
private Long id;
private String name;
@Column(name = "is_deleted")
private Boolean deleted;
}
UserEntity user=new UserEntity();
user.setName("smallbun");
s.persist(user);
Error:
org.hibernate.exception.SQLGrammarException: could not prepare statement [Duplicate column name "IS_DELETED"; SQL statement:
insert into "user" (is_deleted,name,is_deleted,id) values (?,?,false,?) [42121-224]] [insert into "user" (is_deleted,name,is_deleted,id) values (?,?,false,?)]