天天看點

SqlMapClient operation; bad SQL grammar []; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException: InlineParameterMap

<select id="getResByName" resultClass="Resources" parameterClass="java.lang.String">

    select ID id,RESNAME resname from DIR_RESOURCES where RESNAME = #value# ;

   </select>

ibatis 語句切忌 不用加“;”否則就杯具了!

SqlMapClient operation; bad SQL grammar []; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException: InlineParameterMap

把 <select></select> 标簽中,SQL語句的 ; 去掉,就成功了!