| | |
| | | <!--根据指定条件获取农户数据--> |
| | | <select id="getClients" resultType="com.dy.pipIrrGlobal.voSe.VoClient"> |
| | | SELECT |
| | | (@i:=@i+1) AS id, |
| | | CAST(cli.countyId AS char) AS countyId, |
| | | dis_con.name AS countryName, |
| | | CAST(cli.townId AS char) AS townId, |
| | |
| | | LEFT JOIN ba_block blo ON cli.blockId = blo.id |
| | | LEFT JOIN pr_divide divi ON cli.divideId = divi.id |
| | | LEFT JOIN se_water_type wat ON cli.typeId = wat.id |
| | | , (SELECT @i:=0) AS itable |
| | | <where> |
| | | AND cli.disabled = 0 |
| | | AND cli.deleted = 0 |
| | |
| | | |
| | | <!--根据农户编号获取5级行政区划代码--> |
| | | <select id="getAreaCodeByNum" resultType="java.lang.Long"> |
| | | SELECT districtNum FROM se_client WHERE clientNum = ${clientNum} |
| | | SELECT districtNum FROM se_client WHERE clientNum = ${clientNum} LIMIT 0,1 |
| | | </select> |
| | | |
| | | <!--根据农户编号获取5级行政区划串areaCode,补卡过程中开新卡使用--> |
| | |
| | | |
| | | <!--根据农户编号获取农户ID--> |
| | | <select id="getClientIdByNum" resultType="java.lang.Long"> |
| | | SELECT id FROM se_client WHERE clientNum = ${clientNum} |
| | | SELECT id FROM se_client WHERE clientNum = ${clientNum} LIMIT 0,1 |
| | | </select> |
| | | |
| | | <!--根据电话号码获取农户ID--> |