2 Replies Latest reply: Apr 23, 2012 11:50 AM by gdarling - oracle RSS

    hello,ask for help about PLS-00123:program too large

    930916
      there is the problem i meet:
      database:oracle 9i R2
      operating system:WINDOWS XP SP3
      Now,i create a winform by C# was used to import the data from Excel to ORACLE
      when i insert the data into table more than 800+ column,it was no work and say“PLS-00123:program too large”...
      how to let it work,please help,important for me...it's my homework
      the sql is:
      BEGIN
      insert into table values('1','1') ;
      insert into table('2','2');
      insert into table values('1','1') ;
      ----------about 900rows----------
      insert into table values('903','903') ;
      COMMIT;
      EXCEPTION
      WHEN OTHERS THEN
      ROLLBACK;
      END;


      Poor student from Asia
      Mao,L
        • 1. Re: hello,ask for help about PLS-00123:program too large
          931392
          Dear linmao,

          once i came across same problem i resolved it by starting transactions for each set of 100 rows than another hundered and in the end i commited all transactions and in case of exception i rolled back all. try this may be this would help you though i know it is not proper solution.

          Regards,
          Akass Developer
          [Oracle Database|http://www.questions-interviews.com/oracle/database.aspx]

          Edited by: 928389 on Apr 18, 2012 12:01 AM
          • 2. Re: hello,ask for help about PLS-00123:program too large
            gdarling - oracle
            As the error message says, the plsql block is simply too large. You can break it up into smaller blocks, or better yet do it a different way as that's really not a very efficient method.

            You might want to look into the Array Binding feature of ODP.NET, and here's an example walkthrough by my buddy Mark.
            http://www.oracle.com/technetwork/issue-archive/2009/09-sep/o59odpnet-085168.html

            Greg