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

Home -> Community -> Usenet -> c.d.o.misc -> Re: PL/SQL HELP: Dynamic TABLE name from SQL query

Re: PL/SQL HELP: Dynamic TABLE name from SQL query

From: Peter Schneider <pschneider.ctj_at_metronet.de>
Date: 1997/10/09
Message-ID: <343c1f20.12802348@pop-news.metronet.de>#1/1

On Wed, 08 Oct 1997 15:06:27 -0400, Patrick Drouin <patrick.drouin_at_nortel.com> wrote:

>Hello everyone,
>
> Here's my problem : I want to be able to read a table's name from a
>table where I keep some information and then use this information in a
>SELECT statement. Can I get all of my SELECT statement build in a
>variable or in a field in a temp database and then execute the string?
>That sounds easy and I am sure that it can be done in Oracle but I just
>can't figure out how...
>
> Ciao, Patrick

Hi Patrick,

have a look at Oracle standard package DBMS_SQL. It allows for the execution of dynamic SQL, and you really can do some tricky things with it.

Hope this helps,
Peter

Peter Schneider
pschneider.ctj_at_metronet.de Received on Thu Oct 09 1997 - 00:00:00 CDT

Original text of this message

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