Home > Back-end >  Springboot mybatisplus key field will automatically add single quotes, how take out
Springboot mybatisplus key field will automatically add single quotes, how take out

Time:11-28

Springboot + mybatisplus + ms is essentially

The status field will automatically be combined with single quotes, how to get rid of single quotes.

# # # Error querying the database. Cause: com. Microsoft. Essentially. JDBC. SQLServerException: "`" near a syntax Error,
# # # The error may exist in The com/mysiteforme/org/dao/ScEmpDao Java (best guess)
# # # The error may involve defaultParameterMap
# # # The error occurred while setting The parameters
AS # # # SQL: SELECT empid empid, empcode, empname, departid, departcode, companyid, companycode, ` status `, Head, email, phone, jointime, idcard, Sex, remark, createcode, updatecode, updatetime, PWD, createtime, Lastupdate, voip, tel, fax, birthday, age and workage, workplace, empgenre, empProperty, emp01, emp02, emp03, emp04, emp05, worksign FROM SC_EMP WHERE (empcode=?)
# # # Cause: com. Microsoft. Essentially, the JDBC. SQLServerException: "`" near a syntax error,
; Uncategorized SQLException; SQL state [S0001]; The error code [102]. "`" have a syntax error, near; Nested exception is com. Microsoft. Essentially, JDBC. SQLServerException: "`" near a syntax error,

CodePudding user response:

Status is a key word, database in mysql is `

In SQL server should be add [status], see if framework to help you replace

CodePudding user response:

reference 1st floor LCL_data response:
status is a key word, database in mysql is `

In SQL server should be add [status], see if the framework to help you replace the


Is mybatis - plus automatically added if, don't know where you can configure to remove this.

CodePudding user response:

No one encountered this kind of situation?

CodePudding user response:

Reply to ask for the first time, or water, are all what to do is to infuse water? Ask a question all not a line

CodePudding user response:

Send the configuration file, you this is the from the front, don't usually have a fixed?

CodePudding user response:

Wrapper. And (" date=curdate () ");
In this form

CodePudding user response:

How to solve this problem, consult
  • Related