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 Problem

Re: PL/SQL Problem

From: Thomas Kyte <tkyte_at_us.oracle.com>
Date: Fri, 17 Apr 1998 14:22:53 GMT
Message-ID: <35386577.6985915@192.86.155.100>


A copy of this was sent to Lehner Eveline <a9325237_at_unet.univie.ac.at> (if that email address didn't require changing) On Fri, 17 Apr 1998 14:19:19 +0200, you wrote:

>I would like to save the result of a (dynamic!) select-statement in a
>table, because I would like to access the attribute-names.
>I've tried it with DBMS SQL but is there a possibility to get the name
>of the attributes? That would be very important.
>
>CREATE TABLE ... AS SELECT ... just allow subqueries (no ORDER BY!).
>
>Thanks for any help!
>Eve

Oracle8 adds functions to dbms_sql that allow you to describe the columns of a result set (so you can get their names and types and all). In the meanwhile, why don't you:

create VIEW as SELECT ......

Instead of creating a table. That way, you can still query the data dictionary to get the names and types and then just select from the view...  

Thomas Kyte
tkyte_at_us.oracle.com
Oracle Government
Herndon VA  

http://govt.us.oracle.com/ -- downloadable utilities  



Opinions are mine and do not necessarily reflect those of Oracle Corporation  

Anti-Anti Spam Msg: if you want an answer emailed to you, you have to make it easy to get email to you. Any bounced email will be treated the same way i treat SPAM-- I delete it. Received on Fri Apr 17 1998 - 09:22:53 CDT

Original text of this message

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