<selectid="getUserListLimit"resultMap="getUserList">
select user.* from smbms_user as user
<trimprefix="WHERE"prefixOverrides="AND |OR "><iftest="userName != null and userName != ''">
and user.userName like Concat('%',#{userName},'%')
</if><iftest="userRole != null">
and user.userRole=#{userRole}
</if></trim>
order by creationDate DESC
LIMIT #{from},#{pageSize}
</select>