PLSQ perform the same sql, dynamically assembled using mybatis execution time is very slow to solve the problem

As stated, the project encountered the same sql, plsql execution soon, almost a second, but when used mybatis framework in the program, but it is very slow, provided that the dynamic assembly of sql. In the parameters used to write dead, very slow effect does not occur. Finally found using # {xxx} to query very slow injection parameters, using the $ {xxx} when plsq query and query almost the same time.

Changing ago

After the change 

After the specific reasons for the need to understand the underlying mybatis.

Guess you like

Origin www.cnblogs.com/huyande/p/12557982.html