我想使用Query DSL移动此查询。我怎样才能做到这一点?
约束
TB_FR_MENU_AUTH_MAP和TB_FR_MENU_PAGE_INFO不直接相关,但它们通过另一个表连接。
它有动态查询。
SELECT B.PAGE_URL, A.WORKGROUP_SQ
FROM TB_FR_MENU_AUTH_MAP A INNER JOIN TB_FR_MENU_PAGE_INFO B
ON A.MENU_SQ = B.MENU_SQ
AND ((B.READ_YN = 1 AND B.UPDATE_YN = 0 AND B.EXECUTE_YN = 0 AND A.READ_YN = B.READ_YN) OR
(B.READ_YN = 0 AND B.UPDATE_YN = 1 AND B.EXECUTE_YN = 0 AND A.UPDATE_YN = B.UPDATE_YN) OR
(B.READ_YN = 0 AND B.UPDATE_YN = 0 AND B.EXECUTE_YN = 1 AND A.EXECUTE_YN = B.EXECUTE_YN))
WHERE 1=1
<if test="pageUrl != null ">
AND B.PAGE_URL = #{pageUrl}
</if>