Skip to content

[BUG] #242

Open
Open
[BUG]#242
@whatmiss

Description

@whatmiss

测试模块:demo-orm-jpa
数据库的表有父子关系:
CREATE TABLE orm_department (
id int NOT NULL AUTO_INCREMENT COMMENT '主键',
name varchar(32) NOT NULL COMMENT '部门名称',
superior int DEFAULT NULL COMMENT '上级id',
levels int NOT NULL COMMENT '层级',
order_no int NOT NULL DEFAULT '0' COMMENT '排序',
create_time datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
last_update_time datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '上次更新时间',
PRIMARY KEY (id)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Spring Boot Demo Orm 系列示例表

然后查询处理的结果会这样无限循环,这是为什么呢?
查询方式(两种):

// List departmentList = departmentDao.findDepartmentsByLevels(1);
List departmentList = departmentDao.findAll();
ret.put("data", departmentList);
return ret;

image

Metadata

Metadata

Assignees

Labels

bug错误

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions