|
@@ -36,6 +36,10 @@
|
|
</where>
|
|
</where>
|
|
</delete>
|
|
</delete>
|
|
|
|
|
|
|
|
+ <select id="queryWeek" resultType="map" parameterType="map">
|
|
|
|
+ select year "year",week "week" from market_base_week where current date>=begin_date and current date <![CDATA[ <= ]]> end_date
|
|
|
|
+ </select>
|
|
|
|
+
|
|
<update id="updateYbh" parameterType="map">
|
|
<update id="updateYbh" parameterType="map">
|
|
UPDATE MARKET_BASE_IMPORT A SET A.IS_IMPORT='2'
|
|
UPDATE MARKET_BASE_IMPORT A SET A.IS_IMPORT='2'
|
|
WHERE (a.year,a.week) in (select year,week from market_base_week where current date>=begin_date and current date <![CDATA[ <= ]]> end_date)
|
|
WHERE (a.year,a.week) in (select year,week from market_base_week where current date>=begin_date and current date <![CDATA[ <= ]]> end_date)
|
|
@@ -43,6 +47,18 @@
|
|
JOIN V_B_CLIENT B ON A.CLIENT_CODE=B.CLIENT_CODE AND A.COUNTY_CODE=B.COUNTY_CODE and b.county_code=#{countyCode})
|
|
JOIN V_B_CLIENT B ON A.CLIENT_CODE=B.CLIENT_CODE AND A.COUNTY_CODE=B.COUNTY_CODE and b.county_code=#{countyCode})
|
|
</update>
|
|
</update>
|
|
|
|
|
|
|
|
+
|
|
|
|
+ <update id="updateZdh1" parameterType="map">
|
|
|
|
+ UPDATE MARKET_BASE_IMPORT A SET A.YBH=(SELECT TYPE FROM MARKET_SAMPLE_ZD B WHERE A.CLIENT_CODE=B.CLIENT_CODE)
|
|
|
|
+ WHERE a.year=#{year} and a.week=#{week}
|
|
|
|
+ AND A.CLIENT_CODE IN (SELECT CLIENT_CODE FROM MARKET_SAMPLE_ZD WHERE COUNTY_CODE=#{countyCode})
|
|
|
|
+ </update>
|
|
|
|
+
|
|
|
|
+ <update id="updateZdh2" parameterType="map">
|
|
|
|
+ UPDATE HBYC.MARKET_BASE_IMPORT A SET A.IS_IMPORT='1'
|
|
|
|
+ WHERE a.year=#{year} and a.week=#{week} AND A.YBH IN ('4','5','6','7') AND A.IS_IMPORT='0'
|
|
|
|
+ </update>
|
|
|
|
+
|
|
<select id="selectSourceByClientId" resultType="am.lodge.platform.model.AdmissionsSource">
|
|
<select id="selectSourceByClientId" resultType="am.lodge.platform.model.AdmissionsSource">
|
|
SELECT bas.id id,bas.name name
|
|
SELECT bas.id id,bas.name name
|
|
from buss_admissions_source bas LEFT JOIN buss_client_source bcs on bas.ID=bcs.SOURCE_ID
|
|
from buss_admissions_source bas LEFT JOIN buss_client_source bcs on bas.ID=bcs.SOURCE_ID
|