在Redshift DB中插入数据时获取异常

时间:2017-10-30 06:35:25

标签: spring-data-jpa amazon-redshift

从数据库中获取数据当尝试在Redshift数据库中插入数据获取异常时,它正常工作 我的POJO课程: Quote.java

@Entity
public class Quote {
@Id
@GeneratedValue(strategy= GenerationType.AUTO)
private Integer id;
@Column(name="user_name")
private String username;
private String quote;
}

获得例外:

com.amazon.support.exceptions.ErrorException: [Amazon](500310) Invalid operation: relation "hibernate_sequence" does not exist;

我们无法在Redshift中创建序列,但我们可以在postgresql中创建序列 当我连接redshift + spring-data-jpa时,它正在使用postgresql db

hbm2ddl.auto = update

我也尝试过身份

0 个答案:

没有答案