CREATE OR REPLACE procedure sp_contract_tochecktable(p_合同号 contracttable.合同号%TYPE) as
v_ContractTableRecord V_RCONTRACT%ROWTYPE;
v_CustomerRecord V_CUSTOMER.CUST_GRAD_NAME%ROWTYPE;
begin
select a.* ,b.CUST_GRAD_NAME into v_ContractTableRecord, v_CustomerRecord from V_RCONTRACT a,v_customer b where b.CN_COMP_NAME(+)=a.供方
where a.合同号=p_合同号;
begin
insert into beijian.contractchecktable values(v_ContractTableRecord.合同号,v_ContractTableRecord.合同总金额,v_CustomerRecord,'','','A');
end;
commit;
end sp_contract_tochecktable;我的意思是把合同号=p_合同号插入该表里,这个存储过程为什么不对呢?小弟才学,请各位老大帮忙,谢谢
v_ContractTableRecord V_RCONTRACT%ROWTYPE;
v_CustomerRecord V_CUSTOMER.CUST_GRAD_NAME%ROWTYPE;
begin
select a.* ,b.CUST_GRAD_NAME into v_ContractTableRecord, v_CustomerRecord from V_RCONTRACT a,v_customer b where b.CN_COMP_NAME(+)=a.供方
where a.合同号=p_合同号;
begin
insert into beijian.contractchecktable values(v_ContractTableRecord.合同号,v_ContractTableRecord.合同总金额,v_CustomerRecord,'','','A');
end;
commit;
end sp_contract_tochecktable;我的意思是把合同号=p_合同号插入该表里,这个存储过程为什么不对呢?小弟才学,请各位老大帮忙,谢谢
where a.合同号=p_合同号; 有两个where?请确认是否笔误。