我无法为下面描述的字段设置空值。我想插入 NULL 作为默认值。
@Column(name = "answer_date",columnDefinition = "TIMESTAMP")
private LocalDateTime answerDate
当我设置 NULL 时,它显示以下错误:
Caused by: org.postgresql.util.PSQLException: ERROR: column "answer_date" is of type timestamp without time zone but expression is of type character varying
我使用 EclipseLink 作为 JPA 实现。