当前位置:网站首页>Solve the problem of @onetomany query falling into circular reference
Solve the problem of @onetomany query falling into circular reference
2022-07-27 12:09:00 【H_ Dsheng】
solve @OneToMany Query caught in circular reference problem
The error report of the problem is as follows :

The main information is :wrapping Result set representing update count of 4>
as well as :exception [Request processing failed; nested exception is java.lang.NullPointerException] with root cause
The original configuration :

The reason for the error is that both classes use the method of urgent loading , It will cause the entity class that has been looking for foreign keys to fall into a loop , To report a mistake .
Solution : Change to as needed LAZY that will do
@OneToMany( fetch = FetchType.LAZY)
success result:
Reference material :https://www.v2ex.com/t/541510
I've tried to annotate it , But it didn't solve my problem , It turned out to be fetch The problem of .
边栏推荐
- The first case of monkeypox in pregnant women in the United States: the newborn was injected with immunoglobulin and was safely born
- While loop instance in shell
- Synchronous use reference of the new version of data warehouse (for beginners)
- [machine learning whiteboard derivation series] learning notes --- conditional random fields
- Unexpected harvest of epic distributed resources, from basic to advanced are full of dry goods, big guys are strong!
- JS字符串方法总结
- Write and read system temporary files: createtempfile and tempfilecontent[easy to understand]
- 广东财政多举措助力稳住粮食安全“压舱石”
- CH340模块无法识别/烧写不进的一种可能性
- Matlab draws Bode diagram with time delay system
猜你喜欢

Interaction free shell programming

Idea: can't use subversion command line client: SVN solution

Finding the finite zero point of transfer function under different sampling periods

解决@OneToMany查询陷入循环引用问题

go入门篇 (4)

广东:剧本杀等新行业新业态场所,消防安全监管不再“缺位”

Lonely young people can't quit jellycat

MySQL数据库主从复制集群原理概念以及搭建流程

Shell script text three swordsmen sed

LNMP架构搭建(部署Discuz论坛)
随机推荐
USB network card drive data stream
图像分割 vs Adobephotoshop(PS)
Principle of PWM and generation of PWM wave
STS download tutorial (the solution cannot be downloaded on the include official website)
Arduino常见供电问题与解决
In the first half of the year, the number of fires decreased by 27.7%. Guangdong will improve the fire safety quality of the whole people in this way
Keil MDK compilation appears..\user\stm32f10x H (428): error: # 67: expected a "}" wrong solution
w.r.t. ; i.e.;etc.;e.g.是什么意思
Conversion between multiple bases
Solution of digital tube flash back after proteus8 professional version cracking
你尚未连接代理服务器可能有问题或地址不正确(如何查看代理服务器ip)
解决方案:Can not issue executeUpdate() or executeLargeUpdate() for SELECTs
While loop instance in shell
How to make a graph? Multiple subgraphs in a graph are histogram (or other graphs)
[machine learning whiteboard derivation series] learning notes --- conditional random fields
Why is ack=seq+1 when TCP shakes hands three times
Mysql8msi installation tutorial (database mysql installation tutorial)
Sword finger offer notes: t58 - ii Rotate string left
Makefile template
Source code compilation and installation lamp