|
@@ -682,22 +682,30 @@
|
|
|
modes.land_use_mode,
|
|
|
COUNT(cooperatives.land_use_mode) AS count
|
|
|
FROM
|
|
|
- (SELECT '全程托管' AS land_use_mode
|
|
|
- UNION ALL
|
|
|
- SELECT '流转+机械'
|
|
|
- UNION ALL
|
|
|
- SELECT '流转'
|
|
|
- UNION ALL
|
|
|
- SELECT '流转+托管') AS modes
|
|
|
+ (
|
|
|
+ SELECT '全程托管' AS land_use_mode
|
|
|
+ UNION ALL
|
|
|
+ SELECT '流转+机械'
|
|
|
+ UNION ALL
|
|
|
+ SELECT '流转'
|
|
|
+ UNION ALL
|
|
|
+ SELECT '流转+托管'
|
|
|
+ ) AS modes
|
|
|
LEFT JOIN
|
|
|
- centerdata_t_farm_agricultural_cooperatives AS cooperatives
|
|
|
+ (
|
|
|
+ SELECT
|
|
|
+ a.land_use_mode
|
|
|
+ FROM
|
|
|
+ centerdata_t_farm_agricultural_cooperatives a
|
|
|
+ LEFT JOIN ${database_system}.sys_dept d ON d.dept_id = a.dept_id
|
|
|
+ <where>
|
|
|
+ ${params.dataScope}
|
|
|
+ </where>
|
|
|
+ ) AS cooperatives
|
|
|
ON
|
|
|
modes.land_use_mode = cooperatives.land_use_mode
|
|
|
- left join
|
|
|
- ${database_system}.sys_dept d on d.dept_id = cooperatives.dept_id
|
|
|
- <where>${params.dataScope}</where>
|
|
|
GROUP BY
|
|
|
- modes.land_use_mode
|
|
|
+ modes.land_use_mode;
|
|
|
</select>
|
|
|
|
|
|
<select id="getBusinessType" resultType="map">
|
|
@@ -705,22 +713,34 @@
|
|
|
modes.business_type,
|
|
|
COUNT(cooperatives.land_use_mode) AS count
|
|
|
FROM
|
|
|
- (SELECT '股份制' AS business_type
|
|
|
+ (
|
|
|
+ SELECT
|
|
|
+ '股份制' AS business_type
|
|
|
UNION ALL
|
|
|
- SELECT '土地托管型'
|
|
|
+ SELECT
|
|
|
+ '土地托管型'
|
|
|
UNION ALL
|
|
|
- SELECT '提供服务'
|
|
|
+ SELECT
|
|
|
+ '提供服务'
|
|
|
UNION ALL
|
|
|
- SELECT '农民专业合作经济组织') AS modes
|
|
|
+ SELECT
|
|
|
+ '农民专业合作经济组织'
|
|
|
+ ) AS modes
|
|
|
LEFT JOIN
|
|
|
- centerdata_t_farm_agricultural_cooperatives AS cooperatives
|
|
|
- ON
|
|
|
- modes.business_type = cooperatives.business_type
|
|
|
- left join
|
|
|
- ${database_system}.sys_dept d on d.dept_id = cooperatives.dept_id
|
|
|
- <where>${params.dataScope}</where>
|
|
|
+ (
|
|
|
+ SELECT
|
|
|
+ a.land_use_mode,
|
|
|
+ a.business_type AS cooperative_business_type,
|
|
|
+ d.dept_id AS department_id
|
|
|
+ FROM
|
|
|
+ centerdata_t_farm_agricultural_cooperatives a
|
|
|
+ LEFT JOIN ${database_system}.sys_dept d ON d.dept_id = a.dept_id
|
|
|
+ <where>
|
|
|
+ ${params.dataScope}
|
|
|
+ </where>
|
|
|
+ ) AS cooperatives ON modes.business_type = cooperatives.cooperative_business_type
|
|
|
GROUP BY
|
|
|
- modes.business_type
|
|
|
+ modes.business_type;
|
|
|
</select>
|
|
|
|
|
|
<select id="getStrawTurnover" resultType="map">
|