Closed
Description
Mysql version: 8.0
JSQLParser verison: 4.3
sql example:
// this is bad sql
SELECT JSON_OBJECT('account',account) as obj FROM tb_team;
// this is success sql
SELECT JSON_OBJECT('account','some string') as obj FROM tb_team;
bad sql exception:
DDL
CREATE TABLE `tb_team` (
`id` bigint(20) NOT NULL COMMENT '雪花id',
`process_instance_id` varchar(64) DEFAULT NULL COMMENT '流程id',
`relevance_id` bigint(20) DEFAULT NULL COMMENT '发布id',
`apply_id` bigint(20) DEFAULT NULL COMMENT '报名id',
`account` varchar(32) DEFAULT NULL COMMENT '学工号',
`originator` varchar(32) DEFAULT NULL COMMENT '发起人',
`team_type` tinyint(4) DEFAULT NULL COMMENT '类型',
`member_type` tinyint(4) DEFAULT NULL COMMENT '成员类型',
`join_type` tinyint(4) DEFAULT NULL COMMENT '加入类型',
`open_status` tinyint(4) DEFAULT NULL COMMENT '成员状态',
`creator` varchar(64) DEFAULT NULL COMMENT '创建者',
`updater` varchar(64) DEFAULT NULL COMMENT '修改者',
`update_time` datetime DEFAULT NULL COMMENT '修改时间',
`deleted` bit(1) DEFAULT b'0' COMMENT '删除标志',
`tenant_id` bigint(20) DEFAULT NULL COMMENT '租户id',
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='队伍成员表';
An exception will occur if the 'account' column comes from the tb_team table
Metadata
Metadata
Assignees
Labels
No labels