Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> INSERT INTO...RETURNING doesn't work ( ORA-00933)

INSERT INTO...RETURNING doesn't work ( ORA-00933)

From: <agonenil_at_gmail.com>
Date: 10 Apr 2005 15:37:30 -0700
Message-ID: <1113172650.843927.38230@l41g2000cwc.googlegroups.com>


hi , i get the following problem :

SQL> Variable tot_sal number;
SQL> begin
  3 INSERT INTO emp select * from emp
  5 RETURNING sum(sal) INTO :tot_sal;
  7 dbms_output.put_line('Total Company Payroll now : ' || to_char(:tot_sal,'$9
99,999.00'));
  9 end;
 11 /
RETURNING sum(sal) INTO :tot_sal;

          *
ERROR at line 5:
ORA-06550: line 5, column 11:
PL/SQL: ORA-00933: SQL command not properly ended ORA-06550: line 3, column 1:
PL/SQL: SQL Statement ignored

altough accrding to http://www.remote-dba.cc/10g_65.htm , it should work.

I'm using 10.1.0.4 on windows.

Any idea ? Received on Sun Apr 10 2005 - 17:37:30 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US