Re: URGENT! How to implement dynamic table in Forms 4.5?

From: <mgumbs_at_hotmail.com>
Date: Tue, 10 Aug 1999 14:46:11 GMT
Message-ID: <7opdve$da4$1_at_nnrp1.deja.com>


To get the number of columns to be parsed, if you chop up your statement before putting it into dbms_sql...

e.g
declare

  v_numfields  number;
  v_stmt1      varchar2(20);
  v_stmt2      varchar2(20);

begin

   v_stmt1 := 'select empno, ename ';
   v_stmt2 := 'from temp';

   v_numfields := length(v_stmt1) - length(replace(vstmt1, ',','')) + 1;

               ..
               ..

end;

Getting the types of field will take a bit more coding as said in the last reply.

Mark

In article <80Pr3.98$Ru.1786_at_nntp.csufresno.edu>,   stevec_at_zimmer.csufresno.edu (Steve Cosner) wrote:
> In article <7omqus$bvo$1_at_news1.mpx.com.au>,
> Phillip H <hzl_at_optusnet.com.au> wrote:
> >I want to display a table field with Forms 4.5. The content of the
table
> >field is dynamic. The number of column and what's for the columns
depend on
> >dynamic SELECT statement. Could someone tell me how to do it? Do you
have a
> >sample code for it?
> >
> >I am wondering if there is not way to do it with Forms4.5, because
nobody
> >responds to my first mail. Please let me know if it's the case.
>
> Yes, there is a way. But it takes lots of time and coding. You would
> have to use Oracle's DBMS_SQL dynamic SQL package and quite a bit of
> your own parsing of the select statement to determine the types of
> columns returned.
>
> I've written something similar, a dynamic utility form that will
> display and update practically any Oracle table. But it does not
> start from a select statement. You can read about it and download the
> fmx from my website and give it a try.
>
> Steve Cosner
> http://members.aol.com/stevec5088
>
>

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't. Received on Tue Aug 10 1999 - 16:46:11 CEST

Original text of this message