Link to home
Start Free TrialLog in
Avatar of iamtechnical
iamtechnical

asked on

Re: COMPILATIION

When i am trying to compile it, it throwing error, but i am unable to find any error

/* Formatted on 2011/05/12 15:12 (Formatter Plus v4.8.8) */
CREATE OR REPLACE FUNCTION pr_nccr_tm (
   revenuetype   IN   INT,
   project       IN   VARCHAR2,
   task          IN   VARCHAR2,
   end_date      IN   DATE
)
   RETURN NUMBER
IS
   v_revenuetype   INT;
   v_project       VARCHAR2 (15);
   v_task          VARCHAR2 (25);
   v_end_date      DATE;
   v_nccr          NUMBER;
BEGIN
   v_revenuetype := revenuetype;
   v_project := project;
   v_task := task;
   v_end_date := end_date;

   --dbms_output.put_line('v_revenuetype is ' || v_revenuetype);
   IF v_revenuetype = 1
   THEN
      v_nccr := pr_nccr_tm1 (v_project, v_task, v_end_date);
      RETURN v_nccr;
   -- DBMS_OUTPUT.put_line ('1.NCCR IS  ' || v_nccr);
   ELSIF v_revenuetype = 2
   THEN
      v_nccr := pr_nccr_tm2 (v_project, v_task, v_end_date);
      -- dbms_output.put_line('2.NCCR IS  ' || v_nccr);
      RETURN v_nccr;
   ELSE
      v_nccr := pr_nccr_tm3 (v_project, v_task, v_end_date);
      RETURN v_nccr;
   -- dbms_output.put_line('3.NCCR IS  ' || v_nccr);
   END IF;
EXCEPTION
   WHEN OTHERS
   THEN
      DBMS_OUTPUT.put_line ('ERROR IS ' || SQLERRM);
END pr_nccr_tm;
/
Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

What is the error message and line number given in the error?
what is the error that is thrown?

check user_errors
Are you in the same schema as the owner of the pr_nccr_tmX functions?

Do you have execute permission on them?

If I comment out those calls, I can compile your function just fine.
Avatar of iamtechnical

ASKER

i am unable to see error,
just blank clip borad
i am using toad
when i press details tab
it showing
this The Instant Message Index file, C:\PROGRA~1\QUESTS~1\KNOWLE~1\KXMsgs.ini , is corrupted, please contact support.

but other funnctions are working well
the syntax itself is correct so my guess is you're getting

PLS-00201: identifier 'PR_NCCR_TM1' must be declared
PLS-00201: identifier 'PR_NCCR_TM2' must be declared
PLS-00201: identifier 'PR_NCCR_TM3' must be declared


if so,  either that function doesn't exist
or the owner of the function you are creating does not have execute privileges on them
or those functions are owned by another schema and you don't have a synonym for them.
ASKER CERTIFIED SOLUTION
Avatar of Sean Stuber
Sean Stuber

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
no i actually compiled those functions in the schema which i am working, just before creating this function
thanks mannnnn got it, i used wrong number of arguments