简体   繁体   中英

Hibernate. How can we set name of PK/FK using annotations?

We have hibernate-based system and customer wants to get human-readable names of PK and FK. In our project we use annotated entity classes.

Is it renaming possible?

您可以尝试@ForeignKey注释( Hibernate注释文档在“与单个关联相关的注释”一章下显示了一个示例)。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM