1. 程式人生 > 資料庫 >MySQL常見錯誤及排查(持續更新中)

MySQL常見錯誤及排查(持續更新中)

錯誤一:

        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 'LIMIT 20' at line 3

原因:

         resultMap裡的department_id的引數型別應該為integer,而不是varchar