Mapper.xml
resultType定义为java.lang.Integer
<select id="countCountry" resultType="java.lang.Integer">
select count(*) from sys_area where pid=#{streetId};
</select>
Mapper.java
public int countCountry(@Param("streetId") String streetId);
参考
https://blog.csdn.net/weistin/article/details/79864150