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: plsql programmatic alternative to desc <table_name>

Re: plsql programmatic alternative to desc <table_name>

From: Mark <mark.hamlin_at_artdigital.co.uk>
Date: Tue, 21 May 2002 10:23:10 +0100
Message-ID: <acd3pm$6e4$1@pheidippides.axion.bt.co.uk>


Sorry for the ambiguity. I meant refering to a column by its position within the table rather than its name. Helps me itereate through all the columns of a table to create hmtl forms etc without having to know anyhting about the design of the table in advance.

I want to create a plsql application to view and update any table using a web page. I want the forms and update sql to be produced dynamically after being passed a table name.

Using user_tab_columns I could easily dynamically put together the select and insert/update query using a ref cursor. But how then can I 1) iterate through the columns for display and 2) deal with the unknown number of arguments coming back from the web form, will an array of varchars as the in parameter grab them all?

Cheers,
Mark

"Bricklen Anderson" <bricklen_at_shaw.ca> wrote in message news:3CE936DB.87ADD9DD_at_shaw.ca...
> take a look at user_tab_columns and user_tables.
>
> Do you mean assigning column names their positional value through the
> forms? If so, what benefit is there to doing that? Saves typing? Or do
> you want to be able to (re)create indexes on the fly (?? again, if so,
> why?).
>
>
>
> Mark wrote:
> >
> > I want forms constructed dynamically from table defenitions. Is there a
> > programmatic alternative to SQL*Plus desc command.
> > For starters I want field lengths to constrain form input.
> >
> > If possible I would also like to find out column names so I can
dynamically
> > create the entire form given a table name. Being able to index the
columns
> > by number is very useful in this area (is it possible?).
> >
> > Many thanks,
> > Mark
Received on Tue May 21 2002 - 04:23:10 CDT

Original text of this message

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