1bd798cb3364d2ab75e6b2bbac4496bf18587c8e.svn-base 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="cn.com.goldenwater.dcproj.dao.BisZhejiangVillRgstrDao">
  4. <resultMap type="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr" id="bisZhejiangVillRgstrResultMap">
  5. <result property="id" column="ID"/>
  6. <result property="objId" column="OBJ_ID"/>
  7. <result property="regsNm" column="REGS_NM"/>
  8. <result property="waterSafeOrPay" column="WATER_SAFE_OR_PAY"/>
  9. <result property="adCode" column="AD_CODE"/>
  10. <result property="persId" column="PERS_ID"/>
  11. <result property="intm" column="INTM"/>
  12. <result property="uptm" column="UPTM"/>
  13. <result property="note" column="NOTE"/>
  14. <result property="dataStat" column="DATA_STAT"/>
  15. <result property="state" column="STATE"/>
  16. <result property="adFullName" column="AD_FULL_NAME"/>
  17. <result property="isPkx" column="IS_PKX"/>
  18. <result property="isFoOver" column="IS_FO_OVER"/>
  19. <result property="villNum" column="VILL_NUM"/>
  20. <result property="proNum" column="PRO_NUM"/>
  21. <result property="lgtd" column="LGTD"/>
  22. <result property="lttd" column="LTTD"/>
  23. <result property="lgtdpc" column="LGTDPC"/>
  24. <result property="lttdpc" column="LTTDPC"/>
  25. </resultMap>
  26. <sql id="table_columns">
  27. ID,
  28. LGTD ,
  29. LTTD ,
  30. LGTDPC ,
  31. LTTDPC ,
  32. OBJ_ID,
  33. REGS_NM,
  34. WATER_SAFE_OR_PAY,
  35. AD_CODE,
  36. PERS_ID,
  37. INTM,
  38. UPTM,
  39. NOTE,
  40. DATA_STAT,
  41. STATE,
  42. AD_FULL_NAME,
  43. IS_PKX,
  44. IS_FO_OVER,
  45. VILL_NUM,
  46. PRO_NUM
  47. </sql>
  48. <sql id="entity_properties">
  49. #{id},
  50. #{lgtd},
  51. #{lttd},
  52. #{lgtdpc},
  53. #{lttdpc},
  54. #{objId},
  55. #{regsNm},
  56. #{waterSafeOrPay},
  57. #{adCode},
  58. #{persId},
  59. #{intm},
  60. #{uptm},
  61. #{note},
  62. #{dataStat},
  63. #{state},
  64. #{adFullName},
  65. #{isPkx},
  66. #{isFoOver},
  67. #{villNum},
  68. #{proNum}
  69. </sql>
  70. <!-- 使用like用法:columnName like concat('%',#columnName#,'%') -->
  71. <sql id="page_where">
  72. <trim prefix="where" prefixOverrides="and | or ">
  73. <if test="objId != null and objId != ''">and OBJ_ID = #{objId}</if>
  74. <if test="regsNm != null and regsNm != ''">and REGS_NM = #{regsNm}</if>
  75. <if test="waterSafeOrPay != null and waterSafeOrPay != ''">and WATER_SAFE_OR_PAY = #{waterSafeOrPay}</if>
  76. <if test="adCode != null and adCode != ''">and AD_CODE = #{adCode}</if>
  77. <if test="persId != null and persId != ''">and PERS_ID = #{persId}</if>
  78. <if test="intm != null">and INTM = #{intm}</if>
  79. <if test="uptm != null">and UPTM = #{uptm}</if>
  80. <if test="note != null and note != ''">and NOTE = #{note}</if>
  81. <if test="dataStat != null and dataStat != ''">and DATA_STAT = #{dataStat}</if>
  82. <if test="state != null and state != ''">and STATE = #{state}</if>
  83. <if test="adFullName != null and adFullName != ''">and AD_FULL_NAME = #{adFullName}</if>
  84. <if test="isPkx != null and isPkx != ''">and IS_PKX = #{isPkx}</if>
  85. <if test="isFoOver != null and isFoOver != ''">and IS_FO_OVER = #{isFoOver}</if>
  86. <if test="villNum != null and villNum != ''">and VILL_NUM = #{villNum}</if>
  87. <if test="proNum != null and proNum != ''">and PRO_NUM = #{proNum}</if>
  88. </trim>
  89. </sql>
  90. <select id="get" resultMap="bisZhejiangVillRgstrResultMap" parameterType="String" >
  91. select <include refid="table_columns" /> from BIS_ZHEJIANG_VILL_RGSTR where ID = #{id}
  92. </select>
  93. <select id="getBy" resultMap="bisZhejiangVillRgstrResultMap">
  94. select <include refid="table_columns" /> from BIS_ZHEJIANG_VILL_RGSTR <include refid="page_where" />
  95. </select>
  96. <select id="findAll" resultMap="bisZhejiangVillRgstrResultMap">
  97. select <include refid="table_columns" /> from BIS_ZHEJIANG_VILL_RGSTR
  98. </select>
  99. <select id="findList" resultMap="bisZhejiangVillRgstrResultMap">
  100. select <include refid="table_columns" /> from BIS_ZHEJIANG_VILL_RGSTR <include refid="page_where" />
  101. </select>
  102. <select id="selectCount" resultType="int" >
  103. select count(ID) from BIS_ZHEJIANG_VILL_RGSTR <include refid="page_where" />
  104. </select>
  105. <insert id="insert" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr">
  106. insert into BIS_ZHEJIANG_VILL_RGSTR( <include refid="table_columns" /> )
  107. values ( <include refid="entity_properties" /> )
  108. </insert>
  109. <delete id="delete" parameterType="java.lang.String">
  110. delete from BIS_ZHEJIANG_VILL_RGSTR where ID = #{id}
  111. </delete>
  112. <delete id="deleteBy" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr">
  113. delete from BIS_ZHEJIANG_VILL_RGSTR <include refid="page_where" />
  114. </delete>
  115. <update id="deleteInFlag" parameterType="java.lang.String">
  116. update BIS_ZHEJIANG_VILL_RGSTR set flag_valid = 0 where ID = #{id}
  117. </update>
  118. <update id="update" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr">
  119. update BIS_ZHEJIANG_VILL_RGSTR
  120. <trim prefix="set" suffixOverrides=",">
  121. <if test="objId != null and objId != ''">OBJ_ID = #{objId},</if>
  122. <if test="regsNm != null and regsNm != ''">REGS_NM = #{regsNm},</if>
  123. <if test="waterSafeOrPay != null and waterSafeOrPay != ''">WATER_SAFE_OR_PAY = #{waterSafeOrPay},</if>
  124. <if test="adCode != null and adCode != ''">AD_CODE = #{adCode},</if>
  125. <if test="persId != null and persId != ''">PERS_ID = #{persId},</if>
  126. <if test="intm != null">INTM = #{intm},</if>
  127. <if test="uptm != null">UPTM = #{uptm},</if>
  128. <if test="note != null and note != ''">NOTE = #{note},</if>
  129. <if test="dataStat != null and dataStat != ''">DATA_STAT = #{dataStat},</if>
  130. <if test="state != null and state != ''">STATE = #{state},</if>
  131. <if test="adFullName != null and adFullName != ''">AD_FULL_NAME = #{adFullName},</if>
  132. <if test="isPkx != null and isPkx != ''">IS_PKX = #{isPkx},</if>
  133. <if test="isFoOver != null and isFoOver != ''">IS_FO_OVER = #{isFoOver},</if>
  134. <if test="villNum != null and villNum != ''">VILL_NUM = #{villNum},</if>
  135. <if test="proNum != null and proNum != ''">PRO_NUM = #{proNum},</if>
  136. <if test="lgtd != null and lgtd != ''">LGTD = #{lgtd},</if>
  137. <if test="lttd != null and lttd != ''">LTTD = #{lttd},</if>
  138. <if test="lgtdpc != null and lgtdpc != ''">LGTDPC = #{lgtdpc},</if>
  139. <if test="lttdpc != null and lttdpc != ''">LTTDPC = #{lttdpc},</if>
  140. </trim>
  141. <where>ID = #{id}</where>
  142. </update>
  143. <update id="updateBy" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr">
  144. update BIS_ZHEJIANG_VILL_RGSTR
  145. <trim prefix="set" suffixOverrides=",">
  146. <if test="objId != null and objId != ''">OBJ_ID = #{objId},</if>
  147. <if test="regsNm != null and regsNm != ''">REGS_NM = #{regsNm},</if>
  148. <if test="waterSafeOrPay != null and waterSafeOrPay != ''">WATER_SAFE_OR_PAY = #{waterSafeOrPay},</if>
  149. <if test="adCode != null and adCode != ''">AD_CODE = #{adCode},</if>
  150. <if test="persId != null and persId != ''">PERS_ID = #{persId},</if>
  151. <if test="intm != null">INTM = #{intm},</if>
  152. <if test="uptm != null">UPTM = #{uptm},</if>
  153. <if test="note != null and note != ''">NOTE = #{note},</if>
  154. <if test="dataStat != null and dataStat != ''">DATA_STAT = #{dataStat},</if>
  155. <if test="state != null and state != ''">STATE = #{state},</if>
  156. <if test="adFullName != null and adFullName != ''">AD_FULL_NAME = #{adFullName},</if>
  157. <if test="isPkx != null and isPkx != ''">IS_PKX = #{isPkx},</if>
  158. <if test="isFoOver != null and isFoOver != ''">IS_FO_OVER = #{isFoOver},</if>
  159. <if test="villNum != null and villNum != ''">VILL_NUM = #{villNum},</if>
  160. <if test="proNum != null and proNum != ''">PRO_NUM = #{proNum},</if>
  161. <if test="lgtd != null and lgtd != ''">LGTD = #{lgtd},</if>
  162. <if test="lttd != null and lttd != ''">LTTD = #{lttd},</if>
  163. <if test="lgtdpc != null and lgtdpc != ''">LGTDPC = #{lgtdpc},</if>
  164. <if test="lttdpc != null and lttdpc != ''">LTTDPC = #{lttdpc},</if>
  165. </trim>
  166. <include refid="page_where" />
  167. </update>
  168. <!-- 其他自定义SQL -->
  169. <update id="updateVillSum" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr" >
  170. update BIS_ZHEJIANG_VILL_RGSTR set VILL_NUM = #{villNum} where ID = #{id}
  171. </update>
  172. <update id="updateProSum" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr" >
  173. update BIS_ZHEJIANG_VILL_RGSTR set PRO_NUM = #{proNum} where ID = #{id}
  174. </update>
  175. <update id="updateAllNum" parameterType="cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr">
  176. update BIS_ZHEJIANG_VILL_RGSTR set PRO_NUM = #{proNum},VILL_NUM = #{villNum} where ID = #{id}
  177. </update>
  178. <select id="pageNotAddRegstr" resultType="cn.com.goldenwater.dcproj.dto.AttCountryDto"
  179. parameterType="cn.com.goldenwater.dcproj.param.CommonParam">
  180. select e.ad_code,e.ad_name,(case when e.is_poveryt is null then '0' else e.is_poveryt end) is_poveryt,e.lgtd,e.lttd,
  181. (case when o.obj_id is null then '0' else '1' end) status,o.obj_id,o.id from att_ad_x_base e
  182. left join bis_insp_all_obj o on e.ad_code=o.code
  183. where o.ptype=#{objType}
  184. <if test="objId !=null and objId !=''">
  185. and o.obj_id=#{objId}
  186. </if>
  187. <if test="name !=null and name !=''">
  188. and e.ad_name like '%${name}%'
  189. </if>
  190. <if test="adCode !=null and adCode !=''">
  191. and e.ad_code like '%${adCode}%'
  192. </if>
  193. <if test="isPoveryt !=null and isPoveryt !=''">
  194. and e.is_poveryt =#{isPoveryt}
  195. </if>
  196. <if test="orderBy !=null and orderBy !=''">
  197. order by ${orderBy}
  198. </if>
  199. </select>
  200. <select id="findNewVillPageByType" parameterType="cn.com.goldenwater.dcproj.param.TypeParam" resultType="cn.com.goldenwater.dcproj.dto.BisNewVillRgstrDto">
  201. select * from (select A.*,CASE WHEN b.state IS NULL THEN '0' ELSE b.state END AS wtdstState,B.Id as regstr_id,B.Id as rgstr_id,B.INTM,(
  202. case WHEN B.is_pkx is null THEN '0' else B.is_pkx END ) as is_pkx,
  203. B.WATER_SAFE_OR_PAY,B.vill_num,B.pro_num
  204. FROM BIS_INSP_ALL_OBJ A
  205. LEFT JOIN BIS_Zhejiang_VILL_RGSTR B
  206. ON A.OBJ_ID = B.OBJ_ID
  207. where A.ptype=#{pType} AND
  208. A.AD_CODE=#{province} AND
  209. REGEXP_LIKE(
  210. A.Id,'^('||
  211. ( case when(SELECT count(id) from BIS_INSP_ALL_RLATION WHERE PERSID =#{presId} AND AD_CODE=#{province})>0 then
  212. (SELECT LISTAGG(id, '|') WITHIN GROUP(ORDER BY PERSID) as
  213. id FROM BIS_INSP_ALL_RLATION WHERE PERSID =#{presId} AND AD_CODE=#{province})
  214. else (select 'non' from dual) end)
  215. ||')')
  216. ) a
  217. where 1=1
  218. <if test="adCode !=null and adCode !=''">
  219. and a.code like '${adCode}%'
  220. </if>
  221. <if test="sttm != null and sttm != '' and entm != null and entm != ''">
  222. AND INTM &gt;= TO_DATE(#{sttm},'YYYY-MM-DD') AND INTM &lt; TO_DATE(#{entm},'YYYY-MM-DD')+1
  223. </if>
  224. <if test="plnaId !=null and plnaId !=''">
  225. and a.id like '${plnaId}%'
  226. </if>
  227. <if test="groupId !=null and groupId !=''">
  228. and a.id like '${groupId}%'
  229. </if>
  230. <if test="state !=null and state !=''">
  231. and wtdstState in (${state})
  232. </if>
  233. <if test="rsName !=null and rsName !=''">
  234. and a.nm like '%${rsName}%'
  235. </if>
  236. order by wtdstState asc
  237. <if test="orderBy != null and orderBy != ''">
  238. ,${orderBy}
  239. </if>
  240. </select>
  241. <!-- 其他自定义SQL -->
  242. <select id="sumNewVillNumAdd" resultType="cn.com.goldenwater.dcproj.dto.SumNewVillNumDto" parameterType="String">
  243. select sum(vill_num) as vill_num,sum(pro_num) as pro_num from (
  244. SELECT COUNT(B.ad_code) vill_num,0 as pro_num,0 as water_num
  245. FROM BIS_ZHEJIANG_DCUSER_REL_VILL B
  246. where B.RGSTR_ID =#{rgstrId}
  247. UNION all
  248. SELECT 0 as vill_num,count(B.id) pro_num,0 as water_num
  249. FROM BIS_ZHEJIANG_COUNTRY_FEE B
  250. where B.RGSTR_ID=#{rgstrId}
  251. ) w
  252. </select>
  253. <select id="findPageList" resultType="cn.com.goldenwater.dcproj.model.BisInspPblm" parameterType="cn.com.goldenwater.dcproj.param.PlbmParam">
  254. select w.* from (
  255. select j.id as oid,j.obj_id,m.pblm_id,m.obj_type,m.insp_pblm_name ,m.insp_pblm_desc,m.pblm_long,m.pblm_lat,s.check_point,
  256. m.new_vill_name,j.nm,m.vill_type,m.has_vedio,m.quote,m.rec_pers,
  257. m.regid,j.code as ad_code,ba.ad_full_name,s.sn_num,p.pers_name,m.WATER_USER_ID,
  258. m.insp_add_desc,m.coll_time,(select l.pnm from bis_insp_all l where l.id=substr(al.id,0,6)) as pnm,
  259. (select org_nm from bis_insp_org where org_id=substr(al.id,4,3)) as org_nm,
  260. m.PBLM_REASON as pblmReason,m.PBLM_SGGTN as pblmSggtn
  261. from (select m.* from BIS_INSP_PBLM m where m.obj_type='41'
  262. ) m
  263. join (select * from BIS_INSP_ALL_OBJ j where j.pType='41' and j.ad_code=#{province}) j on m.obj_id=j.obj_id
  264. join obj_insp_pblms s on m.pblms_type_id=s.guid
  265. left join bis_insp_all al on al.id=j.id
  266. left join bis_insp_all_rlation_pers p on m.rec_pers=p.guid
  267. left join att_ad_x_base ba on j.code=ba.ad_code
  268. ) w
  269. where 1=1
  270. <if test="tabType =='2'.toString()">
  271. and w.entm &lt;to_date(#{nowTime},'yyyy-MM-dd')+1
  272. </if>
  273. <if test="tabType =='1'.toString()">
  274. and w.entm &gt;=to_date(#{nowTime},'yyyy-MM-dd') and w.sttm &lt; to_date(#{nowTime},'yyyy-MM-dd')+1
  275. </if>
  276. <if test="timeType =='1'.toString()">
  277. and w.COLL_TIME >=to_date(#{nowTime},'yyyy-MM-dd')
  278. </if>
  279. <if test="timeType =='2'.toString()">
  280. and w.COLL_TIME &gt;=to_date(#{nowMonth},'yyyy-MM')
  281. </if>
  282. <if test="timeType =='3'.toString()">
  283. and w.COLL_TIME &gt;=to_date(#{nowYear},'yyyy')
  284. </if>
  285. and
  286. REGEXP_LIKE(
  287. W.OID,'^('||
  288. ( case when(SELECT count(id) from BIS_INSP_ALL_RLATION WHERE PERSID =#{presId} and ad_code=#{province})>0 then
  289. (SELECT LISTAGG(id, '|') WITHIN GROUP(ORDER BY PERSID) as
  290. id FROM BIS_INSP_ALL_RLATION WHERE PERSID =#{presId} and ad_code=#{province})
  291. else (select 'non' from dual) end)
  292. ||')')
  293. <if test="villType !=null and villType !=''">
  294. and w.vill_type in (${villType})
  295. </if>
  296. <if test="objIdes != null and objIdes != ''">and OBJ_ID in (${objIdes})</if>
  297. <if test="inspPblmName !=null and inspPblmName !=''">
  298. and w.insp_pblm_name like '${inspPblmName}%'
  299. </if>
  300. <if test="startTime != null and startTime != ''">and COLL_TIME &gt;= TO_DATE(#{startTime},'YYYY-MM-DD')</if>
  301. <if test="findTime != null and findTime != ''">and COLL_TIME=TO_DATE(#{findTime},'YYYY-MM-DD')</if>
  302. <if test="endTime != null and endTime != ''">and COLL_TIME &lt; TO_DATE(#{endTime},'YYYY-MM-DD')+1</if>
  303. <if test="oides != null and oides != ''">and oid in (${oides})</if>
  304. <if test="regid !=null and regid !=''">
  305. and w.regid=#{regid}
  306. </if>
  307. <if test="objId !=null and objId !=''">
  308. and w.obj_id=#{objId}
  309. </if>
  310. <if test="groupId !=null and groupId !=''">
  311. and oid like '${groupId}%'
  312. </if>
  313. <if test="adFullName !=null and adFullName !=''">
  314. and w.AD_FULL_NAMe like '%${adFullName}%'
  315. </if>
  316. <if test="persName !=null and persName !=''">
  317. and w.PERS_NAME like '%${persName}%'
  318. </if>
  319. <if test="nm !=null and nm !=''">
  320. and w.NM like '%${nm}%'
  321. </if>
  322. <if test="orgNm !=null and orgNm !=''">
  323. and w.ORG_NM like '%${orgNm}%'
  324. </if>
  325. <if test="hasVedio !=null and hasVedio !=''">
  326. and w.HAS_VEDIO=#{hasVedio}
  327. </if>
  328. <if test="adCode !=null and adCode !=''">
  329. and w.WATER_USER_ID like '${adCode}%'
  330. </if>
  331. order by w.WATER_USER_ID
  332. <if test="orderBy !=null and orderBy !=''">
  333. ,${orderBy}
  334. </if>
  335. </select>
  336. <select id="findPageByType" resultType="cn.com.goldenwater.dcproj.dto.BisNewVillRgstrDto"
  337. parameterType="cn.com.goldenwater.dcproj.param.TypeParam">
  338. select * from (select A.id,A.Nm,A.Code,A.Obj_Id,A.Lgtd,A.Lttd,A.Lgtdpc,A.Lttdpc,
  339. A.pType,CASE WHEN b.state IS NULL THEN '0' ELSE b.state
  340. END AS wtdstState,B.Id as rgstr_id,ad.ad_full_name,al.pnm as groupName
  341. ,to_char(b.intm,'yyyy-MM-dd HH24:mi:ss') as intm,
  342. to_char(b.uptm,'yyyy-MM-dd HH24:mi:ss') as uptm,B.WATER_SAFE_OR_PAY
  343. FROM BIS_INSP_ALL_OBJ A
  344. LEFT JOIN BIS_Zhejiang_VILL_RGSTR B
  345. ON A.OBJ_ID = B.OBJ_ID
  346. left join ATT_AD_X_BASE ad on b.ad_code = ad.ad_code
  347. left join BIS_INSP_ALL al
  348. on A.id=al.id
  349. where A.ad_code=#{province} and
  350. REGEXP_LIKE(
  351. A.Id,'^('||
  352. ( case when(SELECT count(id) from BIS_INSP_ALL_RLATION WHERE PERSID =#{presId} and ad_code=#{province})>0 then
  353. (SELECT LISTAGG(id, '|') WITHIN GROUP(ORDER BY PERSID) as
  354. id FROM BIS_INSP_ALL_RLATION WHERE PERSID =#{presId} and ad_code=#{province})
  355. else (select 'non' from dual) end)
  356. ||')')
  357. ) a
  358. where ptype=#{pType}
  359. <if test="plnaId !=null and plnaId !=''">
  360. and a.id like '${plnaId}%'
  361. </if>
  362. <if test="state !=null and state !=''">
  363. and wtdstState in (${state})
  364. </if>
  365. <if test="sttm != null and sttm != '' and entm != null and entm != ''">
  366. AND INTM &gt;= TO_DATE(#{sttm},'YYYY-MM-DD') AND INTM &lt; TO_DATE(#{entm},'YYYY-MM-DD')+1
  367. </if>
  368. <if test="groupId !=null and groupId !=''">
  369. and a.id like '${groupId}%'
  370. </if>
  371. <if test="name !=null and name !=''">
  372. and a.nm like '%${name}%'
  373. </if>
  374. <if test="nm !=null and nm !=''">
  375. and a.nm like '%${nm}%'
  376. </if>
  377. <if test="adName !=null and adName !=''">
  378. and a.ad_full_name like '%${adName}%'
  379. </if>
  380. <if test="rsName !=null and rsName !=''">
  381. and a.nm like '%${rsName}%'
  382. </if>
  383. order by wtdstState asc
  384. <if test="orderBy != null and orderBy != ''">
  385. <!--,${orderBy}-->
  386. ,nlssort(nm,'NLS_SORT=SCHINESE_PINYIN_M')
  387. </if>
  388. </select>
  389. </mapper>