Re: Name of table as parameter in PL/SQL

From: Kai Sodemann <Kai.Sodemann_at_memo.ikea.com>
Date: 8 Nov 1999 15:30:09 GMT
Message-ID: <01bf29fe$a1ea92c0$6e49100a_at_pc910-sode.seurope.ikea.com>


Hi

you will have to use dynamic sql with package DBMS_SQL.

Reg Kai

Rodolphe WICHLACZ <rwich_at_cybercable.fr> wrote in article <801r9q$q67$1_at_oceanite.cybercable.fr>...
> Hello,
>
> I want to create a function in PL/SQL with a name of a table as
parameter.
> In this function, I use the <insert into ...> instruction.
>
> I have declared the parameter as char(20). But when I execute the
function,
> an error is detected.
>
> For example : function f (table_name char(20)) return boolean
> is
> begin
> insert into table_name ...
> ...
> end;
>
> When I call f('temp'), the system tell me that table_name is not a table.
> So I think that the program don't replace table_name by its value.
>
> Can you help me ?
>
> Thank you in advance
>
>
> Rodolphe WICHLACZ
> France
>
>
>
Received on Mon Nov 08 1999 - 16:30:09 CET

Original text of this message