An inexplicable error occurs during stored procedure calling:
ORA-00932: inconsistent data types: Should be-, but get-
Refer to the online analysis for the following reasons .... loop Method: Use a cursor. Previously, because the field names to be used are the same, no error is reported when c_row.prod_code is changed to c_row.fund_code, this error is reported because c_row has already specified the fields when it is used for the first time. Only the same fields can be obtained.
-- Check whether the multi-icing product has not been added to the assessment product table. If not, add it.
V_exectime: = sysdate;
For c_row in (
Select a. prod_code | '-' | A. prodalias_name | '-automatically added to the evaluation product table' as MSG, .*
From [email protected]
Where a. prod_name like '% %' and A. prod_code not in (select cpbh from t_jxkh_khcp)
)
Loop
Insert into partition (cpbh, SSGs, cpmc, cplb, cpzt, zczsbl, sfjskhj, tcblfs, tcbl, cosine, xfrq, hdqsrq, hdjzrq, kzbs, BZ, cosine, lrrq, cosine, zhxgsj, is_kfjj, is_k2, srlx)
Values (c_row.prod_code, null, c_row.prodalias_name, '2', '1', 0.60000, '0', null, null, 0, null, 1, to_char (sysdate, 'yyyymmdd'), 1, sysdate, 0, 0, 0 );
Insert into t_gfcp (stockcode, stockname, invalid, percent, is_js_sg, percent_bank, is_khjl)
Values (c_row.prod_code, c_row.prodalias_name, 1, 0.6, 0, 0.6, 0 );
End loop;
-- Check whether the multi-rich product has not been added to the assessment product table. If not, add the product.
V_exectime: = sysdate;
For c_row2 in (
Select a. fund_code | '-' | A. fund_name | '-not included in the assessment product table' as MSG, A. * from [email protected]
Where a. fund_name like '% %' and A. fund_code not in (select cpbh from t_jxkh_khcp)
)
Loop
Insert into partition (cpbh, SSGs, cpmc, cplb, cpzt, zczsbl, sfjskhj, tcblfs, tcbl, cosine, xfrq, hdqsrq, hdjzrq, kzbs, BZ, cosine, lrrq, cosine, zhxgsj, is_kfjj, is_k2, srlx)
Values (c_row2.fund_code, null, c_row2.fund_name, '2', '1', 0.60000, '0', null, null, 0, null, 1, to_char (sysdate, 'yyyymmdd'), 1, sysdate, 0, 0, 0 );
Insert into t_gfcp (stockcode, stockname, invalid, percent, is_js_sg, percent_bank, is_khjl)
Values (c_row2.fund_code, c_row2.fund_name, 1, 0.6, 0, 0.6, 0 );
-- Text message notifications are too troublesome.
-- Agfhd_p_sendsms ('2017 130000046 ', c_row.msg );
End loop;
ORA-00932: inconsistent data types: Should be-, but get-