求已存储过程,存储过程中包含三个Insert语句,然后成功调用!刚学oracle不懂,自己写了执行不正确!

解决方案 »

  1.   


    create or replace  procedure   InsertBaseInfo
    as
    begin
    Insert into studentinfo(studentid,studentname,sex,nation)values('1000003','刘明','男','汉族');
    Insert into studentinfo(studentid,studentname,sex,nation)values('1000003','刘明','男','汉族');
    commit;
    end insertbaseinfo;
     
    execute insertbaseinfo;
      

  2.   

    上面是我写的exec的时候总是出错 
      

  3.   

    过程没错啊......以下调用测试...begin
      -- Call the procedure
      insertbaseinfo;
    end;
      

  4.   

    你INSERT语句单独跑有什么错误没?
    Insert into studentinfo(studentid,studentname,sex,nation)values('1000003','刘明','男','汉族');
      

  5.   

    直接执行 exec insertbaseinfo 出现“ORA-00900: invalid SQL statement”错误
      

  6.   

    单独执行没有错误Insert into studentinfo(studentid,studentname,sex,nation)values('1000003','刘明','男','汉族');在SQLPLUS执行exec insertbaseinfo也没错误
      

  7.   

    你INSERT语句单独跑有什么错误没?
    Insert into studentinfo(studentid,studentname,sex,nation)values('1000003','刘明','男','汉族');一步一步来 ...
      

  8.   

    ORA-00900 invalid SQL statementCause: The statement is not recognized as a valid SQL statement. This error can occur if the Procedural Option is not installed and a SQL statement is issued that requires this option (for example, a CREATE PROCEDURE statement). You can determine if the Procedural Option is installed by starting SQL*Plus. If the PL/SQL banner is not displayed, then the option is not installed.Action: Correct the syntax or install the Procedural Option.
    但是看不明白我要怎么install the Procedural Option选项