Commit 56a61bea authored by 王炜's avatar 王炜

农行回单修复-单行返回多行 to 陆正友

parent 915a0c6f
...@@ -57,16 +57,8 @@ ...@@ -57,16 +57,8 @@
NULL AS payer_name_r, NULL AS payer_name_r,
NULL AS payer_bank_r, NULL AS payer_bank_r,
NULL AS total_amount_r, NULL AS total_amount_r,
COALESCE((SELECT v.code_value_name null AS collection_classes_desc,
FROM sys_code_values_v v, null guarantor_name_duty
csh_transaction_import_temp ct
WHERE v.code = 'DS_COLLECTION_CLASSES'
AND v.code_value = ct.collection_classes
and ct.bp_bank_name = hx.payer_name),
'非保证金类') AS collection_classes_desc,
(SELECT ct.guarantor_name_duty
FROM csh_transaction_import_temp ct
WHERE ct.bp_bank_name = hx.payer_name) guarantor_name_duty
FROM hlcm_ele_abc_bank_slip_trx hx FROM hlcm_ele_abc_bank_slip_trx hx
where hx.create_trx_flag = 'Y' where hx.create_trx_flag = 'Y'
and not exists (select 1 and not exists (select 1
...@@ -127,16 +119,16 @@ ...@@ -127,16 +119,16 @@
a.payer_name payer_name_r, a.payer_name payer_name_r,
a.bank_name payer_bank_r, a.bank_name payer_bank_r,
a.total_amount total_amount_r, a.total_amount total_amount_r,
COALESCE((SELECT v.code_value_name decode(a.collection_classes_desc,
FROM sys_code_values_v v, 'DEPOSIT',
csh_transaction_import_temp ct '保证金类',
WHERE v.code = 'DS_COLLECTION_CLASSES' 'NON_DEPOSIT',
AND v.code_value = ct.collection_classes '非保证金类',
and ct.bp_bank_name = hx.payer_name), 'COMBINED',
'非保证金类') AS collection_classes_desc, '混合类',
(SELECT ct.guarantor_name_duty 'REFUND',
FROM csh_transaction_import_temp ct '日立为优质客户付租金') AS collection_classes_desc,
WHERE ct.bp_bank_name = hx.payer_name) guarantor_name_duty decode(a.guarantor_name_duty, 'Y', '是', 'N', '否') guarantor_name_duty
FROM hlcm_ele_abc_bank_slip_trx hx, hlcm_ele_trx_import_itfc a FROM hlcm_ele_abc_bank_slip_trx hx, hlcm_ele_trx_import_itfc a
where hx.create_trx_flag = 'Y' where hx.create_trx_flag = 'Y'
and a.receipt_no = hx.receipt_no and a.receipt_no = hx.receipt_no
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment