如题,谢谢。
    这个存储过程本来是用在另外一个数据库里的,我要把它拿到另一个数据库,但是只要一编译就会出现ORACLE 断开连接。
    create or replace package body accrual_basis is
 
  function dope_charge(in_custcode in varchar2, --账号
                       in_sysdate  date --统计日期
                       ) return number is
    v_charge number := 0;
    r_c      customers%rowtype;
    r_ca     customerassist%rowtype;
    r_cs     customerservices%rowtype;
    r_s      services%rowtype;
    r_u      unifiedtrfcommon%rowtype;
  begin
    select * into r_c from customers where custcode = in_custcode;
    if (r_c.accountstatus in ('C', 'O')) then
      return 0;
    end if;
    if (r_c.custtype <> 2) then
      return 0;
    end if;
    select * into r_ca from customerassist where custcode = in_custcode;
    if (r_ca.real_mature >= in_sysdate) then
      select *
        into r_cs
        from customerservices
       where custcode = in_custcode;
      select * into r_s from services where servicecode = r_cs.servicecode;
      select *
        into r_u
        from unifiedtrfcommon
       where tariffcode = r_s.tariffcode;
      v_charge := r_u.PERIODBASICRATE;
    end if;
    return v_charge;
  exception
    when others then
      return 0;
  end;
end accrual_basis;
  真是太奇怪了,这里面涉及的表都是存在的。
  麻烦各位高手给支个招,谢谢。。