原因 : Mapper.xml 文件里 < (小于)号 , >(大于)号 ,会被认为是括号,需要额外注意,
解决办法 : 将 < 号换成 < > 号 换成>
SELECT*FROM(SELECT T.*,ROWNUM RN FROM
(SELECT d.d_value AS TIMES,a.arr_date ,a.au_id ,a.arr_id FROM T_ARRANGE A INNER JOIN
T_ADMIN_USER U ON U.AU_ID=a.au_id
INNER JOIN T_DICT D ON D.D_CODE=A.TIME_ID
WHERE D.D_TYPE='WORK_TIME'
ORDER BY A.ARR_DATE DESC ,TIMES)T WHERE AU_ID=#{au_id}) WHERE RN>0 AND RN <=4