问题遇到的现象和发生背景
使用postman测试接口,在到使用框架自带的方法insert时,插入报错
问题相关代码,请勿粘贴截图
这些事报错信息
Error updating database. Cause: java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'order,
sub_order,
family,
sub_family,
genus,
sub_genus,
species,
sub_species,
di' at line 8
The error may exist in com/ljk/commons/mapper/InformationMapper.java (best guess)
The error may involve com.ljk.commons.mapper.InformationMapper.insert-Inline
The error occurred while setting parameters
SQL: INSERT INTO information ( name, b_name, kingdom, phylum, sub_phylum, g_class, sub_class, order, sub_order, family, sub_family, genus, sub_genus, species, sub_species, distribution_area, protection_level, binomial_nomenclature, food, life_time, breed, affect, colour, past_records, natural_enemy, life_habit, population_status, feature, growth_reproduction, pathophoresis, author_id, operating_time, valid_state ) VALUES ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
运行结果及报错内容
我的解答思路和尝试过的方法
我想要达到的结果
可以正确的存储到数据库