【异常】MyBatis提示Cause: java.sql.SQLSyntaxErrorException: Unknown column ‘forbid_time‘ in ‘field list‘

1. Error content

### Error querying database.  Cause: java.sql.SQLSyntaxErrorException: Unknown column 'forbid_time' in 'field list'\n
### The error may exist in com/xxx/mapper/ScenariosConfigMapper.java (best guess)
### The error may involve defaultParameterMap
### The error occurred while setting parameters
### SQL: SELECT  id,utilization,forbid_time,status,create_by,create_time,update_by,update_time  FROM app_scenarios_config           ORDER BY create_time DESC
### Cause: java.sql.SQLSyntaxErrorException: 
Unknown column 'forbid_time' in 'field list'\n; bad SQL grammar []; 
nested exception is java.sql.SQLSyntaxErrorException: 
Unknown column 'forbid_time' in 'field list'

2. Error description

The forbid_time field of a MySQL table is defined in ScenariosConfigMapper, but if it cannot be found in the database, the above error will be reported

Three, error resolution

Just add the forbid_time field directly in a MySQL table

Guess you like

Origin blog.csdn.net/wstever/article/details/130422951