// order by 排序 //<![CDATA[ 值 ]]> 過濾符號 //${}方式會引發SQL註入 //#{} 解析的是占位符 <![CDATA[ order by ${參數1} ${參數2} ]]> 例子: SQL:select * from A where A.id=#{id} id=h ...
// order by 排序
//<![CDATA[ 值 ]]> 過濾符號
//${}方式會引發SQL註入
//#{} 解析的是占位符
<![CDATA[ order by ${參數1} ${參數2} ]]>
例子:
SQL:select * from A where A.id=#{id}
id=hello
解析:select * from A where A.id=?
SQL:select * from A where A.id=#{id}
id=hello
解析:select * from A where A.id=hello