Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

数据库可以使用bean注入的方式 使用@column注解 #14

Open
MAXIAODONGS opened this issue Jul 19, 2019 · 0 comments
Open

数据库可以使用bean注入的方式 使用@column注解 #14

MAXIAODONGS opened this issue Jul 19, 2019 · 0 comments

Comments

@MAXIAODONGS
Copy link

MAXIAODONGS commented Jul 19, 2019

在application.yml中配置
jpa: database: mysql hibernate: ddl-auto: update show-sql: true
实体类中
@Entity public class OrderDetail implements Serializable { @Id private String detailId; /** * 订单id */ @Column private String orderId;

上面这种实现后方便操作不需要建表 创建一个库就行 我已经将修改过的代码提交的我的库里 希望可以相互学习一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant