|
楼主 |
发表于 2017-7-19 11:45:48
|
显示全部楼层
这个SQL看不太明白,但是执行了6-7秒。其他都是几毫秒
exec KSQL: select org.sFID, org.sFName from SA_OPOrg org join SA_OPAuthorize auth on org.sFID like concat(auth.sOrgFID, '%') where org.sValidState=1 and ((auth.sAuthorizeRoleID='RL-SYSTEM') or (auth.sAuthorizeRoleID='RL-USER')) order by org.sSequence
sql:SELECT org.sFID AS sFID, org.sFName AS sFName FROM SA_OPOrg org JOIN SA_OPAuthorize auth ON org.sFID LIKE concat_ws('',auth.SORGFID, ?) WHERE (org.SVALIDSTATE = ?) AND ( (auth.sAuthorizeRoleID = ?) OR (auth.sAuthorizeRoleID = ?) ) ORDER BY org.SSEQUENCE ASC
|
|