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

Home -> Community -> Usenet -> c.d.o.tools -> Re: ORA-00905 error in PL/SQL code

Re: ORA-00905 error in PL/SQL code

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: 2000/05/30
Message-ID: <959716731.26294.0.pluto.d4ee154e@news.demon.nl>#1/1

You can't use into with dbms_sql, you'll need to use dbms_sql.define_column prior to execution dbms_sql.execute_and_fetch in execution
and dbms_sql.column_value to retrieve the result.

Hth,

Sybrand Bakker, Oracle DBA

Gennady <gennadyb_at_halcosoftware.com> schreef in berichtnieuws 3934160a$0$32021_at_fountain.mindlink.net...
> Hello,
> I'm trying to execute the code:
> declare
> c2 number;
> d2 number;
> k number;
> vin_table_name varchar2(30):='MYTABLE';
> begin
> dbms_output.enable;
> c2 := dbms_sql.open_cursor;
> dbms_sql.parse(c2, 'select count(*) into '||k||' from
> '||vin_table_name||'',dbms_sql.native);
> d2:=dbms_sql.execute(c2);
> dbms_output.put_line(k);
> dbms_sql.close_cursor(c2);
> end;
>
> But I get error ORA-00905: missing keyword.
> Could you please give me a hint how to fix the problem?
> Thanks,
> Gennady
>
>
>
Received on Tue May 30 2000 - 00:00:00 CDT

Original text of this message

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