oracle - SQL Package Syntax Error -


i having problem locating error on tapi built "project table". syntax error because not compile, posted code , errors below... if lead me in right direction appreciated.

code

create or replace package body "project_tapi" -------------------------------------------------------------- -- create procedure table "project" procedure "ins_project" (   "p_startdate" in date              default null,   "p_projid"    in number,   "p_empno"     in number            default null,   "p_projname"  in varchar2          default null )   begin    insert "project" (      "startdate",      "projid",      "empno",      "projname"   ) values (       "p_startdate",      "p_projid",      "p_empno",      "p_projname"   );  end "ins_project"; -------------------------------------------------------------- -- update procedure table "project" procedure "upd_project" (   "p_projid" in number,   "p_startdate" in date              default null,   "p_empno"     in number            default null,   "p_projname"  in varchar2          default null,   "p_md5"       in varchar2          default null )     "l_md5" varchar2(32767) := null;  begin    if "p_md5" not null      c1 in (         select * "project"          "projid" = "p_projid" update      ) loop          "l_md5" := "build_project_md5"(            c1."startdate",            c1."projid",            c1."empno",            c1."projname"         );       end loop;    end if;    if ("p_md5" null) or ("l_md5" = "p_md5")       update "project" set         "startdate"   = "p_startdate",         "projid"      = "p_projid",         "empno"       = "p_empno",         "projname"    = "p_projname"      "projid" = "p_projid";   else      raise_application_error (-20001,'current version of data in database has changed since user    initiated update process. current checksum = "'||"l_md5"||'", item checksum = "'||"p_md5"||'".');     end if;  end "upd_project"; -------------------------------------------------------------- -- delete procedure table "project" procedure "del_project" (   "p_projid" in number )   begin    delete "project"    "projid" = "p_projid";  end "del_project"; -------------------------------------------------------------- -- procedure table "project" procedure "get_project" (   "p_projid" in number,   "p_startdate" out date,   "p_empno"     out number,   "p_projname"  out varchar2 )     ignore varchar2(32676); begin    "get_project" (      "p_startdate",      "p_projid",      "p_empno",      "p_projname",      ignore   );  end "get_project"; -------------------------------------------------------------- -- procedure table "project" procedure "get_project" (   "p_projid" in number,   "p_startdate" out date,   "p_empno"     out number,   "p_projname"  out varchar2,   "p_md5"       out varchar2 )   begin    c1 in (      select * "project"       "projid" = "p_projid"    ) loop      "p_startdate" := c1."startdate";      "p_empno"     := c1."empno";      "p_projname"  := c1."projname";       "p_md5" := "build_project_md5"(         c1."startdate",         c1."projid",         c1."empno",         c1."projname"      );   end loop;  end "get_project"; -------------------------------------------------------------- -- build md5 function table "project" function "build_project_md5" (   "p_projid" in number,   "p_startdate" in date              default null,   "p_empno"     in number            default null,   "p_projname"  in varchar2          default null,   "p_col_sep"   in varchar2          default '|'  ) return varchar2    begin    return sys.utl_raw.cast_to_raw(sys.dbms_obfuscation_toolkit.md5(input_string=>       "p_startdate" ||"p_col_sep"||      "p_empno"     ||"p_col_sep"||      "p_projname"  ||"p_col_sep"||      ''   ));   end "build_project_md5";  end "project_tapi";  

error

compilation failed,line 46 (21:08:15) pls-00306: wrong number or types of arguments in call 'build_project_md5'compilation    failed,line 46 (21:08:15) pls-00306: wrong number or types of arguments in call 'build_project_md5'compilation failed,line 46 (21:08:15) pl/sql: statement ignoredcompilation failed,line 93 (21:08:15) pls-00306: wrong number or types of arguments in call 'get_project'compilation failed,line 93 (21:08:15) pl/sql: statement ignoredcompilation failed,line 122 (21:08:15) pls-00306: wrong number or types of arguments in call 'build_project_md5'compilation failed,line 122 (21:08:15) pls-00306: wrong number or types of arguments in call 'build_project_md5'compilation failed,line 122 (21:08:15) pl/sql: statement ignored 

thanks

there lot wrong calling of methods.

for example one:

 "p_md5" := "build_project_md5"(     c1."startdate",     c1."projid", 

the order of fields wrong. should other way around.


Comments

Popular posts from this blog

PHPMotion implementation - URL based videos (Hosted on separate location) -

c# - Unity IoC Lifetime per HttpRequest for UserStore -

I am trying to solve the error message 'incompatible ranks 0 and 1 in assignment' in a fortran 95 program. -