|
@@ -107,22 +107,32 @@
|
|
</select>
|
|
</select>
|
|
<select id="selectMatchList" resultType="java.util.Map">
|
|
<select id="selectMatchList" resultType="java.util.Map">
|
|
SELECT a.book_trade_no,
|
|
SELECT a.book_trade_no,
|
|
- a.book_order_no,
|
|
|
|
- a.`station_code`,
|
|
|
|
- a.`payment_no`
|
|
|
|
- FROM hm_book_trade_order AS a
|
|
|
|
- LEFT JOIN hm_book_order AS b
|
|
|
|
- ON b.book_order_no = a.book_order_no
|
|
|
|
- <![CDATA[ WHERE LEFT (begin_time
|
|
|
|
- , 12)
|
|
|
|
- < CURRENT_DATE
|
|
|
|
- AND LEFT (begin_time
|
|
|
|
- , 12)
|
|
|
|
- > DATE_SUB(CURRENT_DATE
|
|
|
|
- , INTERVAL 31 DAY)
|
|
|
|
- AND a.status <> 4
|
|
|
|
- AND b.book_order_no IS NULL
|
|
|
|
- ]]>
|
|
|
|
|
|
+ a.book_order_no,
|
|
|
|
+ a.`station_code`,
|
|
|
|
+ a.`payment_no`
|
|
|
|
+ FROM hm_book_trade_order a
|
|
|
|
+ LEFT JOIN hm_book_order b
|
|
|
|
+ ON b.book_trade_no = a.book_trade_no
|
|
|
|
+ WHERE a.status != 4
|
|
|
|
+ AND (
|
|
|
|
+ a.`start_time` BETWEEN (CURRENT_DATE - INTERVAL 31 DAY)
|
|
|
|
+ AND (CURRENT_DATE + INTERVAL 31 DAY)
|
|
|
|
+ )
|
|
|
|
+ AND b.book_order_no IS NULL
|
|
|
|
+ UNION
|
|
|
|
+ SELECT a.book_trade_no,
|
|
|
|
+ a.book_order_no,
|
|
|
|
+ a.`station_code`,
|
|
|
|
+ a.`payment_no`
|
|
|
|
+ FROM hm_book_trade_order a
|
|
|
|
+ LEFT JOIN hm_book_order b
|
|
|
|
+ ON b.book_trade_no = a.book_trade_no
|
|
|
|
+ WHERE a.status != 4
|
|
|
|
+ AND (
|
|
|
|
+ a.`start_time` BETWEEN (CURRENT_DATE - INTERVAL 31 DAY)
|
|
|
|
+ AND (CURRENT_DATE + INTERVAL 31 DAY)
|
|
|
|
+ )
|
|
|
|
+ AND b.shop_name IS NULL
|
|
</select>
|
|
</select>
|
|
<select id="selectByBookOrderNo" resultMap="BaseResultMap">
|
|
<select id="selectByBookOrderNo" resultMap="BaseResultMap">
|
|
select
|
|
select
|