Re: Retrieving Variable number of input fields with Web Server

From: Thomas J. Kyte <tkyte_at_us.oracle.com>
Date: 1997/02/08
Message-ID: <32fbdda8.3108229_at_nntp.mediasoft.net>#1/1


do something like:

<input type=hidden name=p_name value="field1"><input type=text name=p_value>
<input type=hidden name=p_name value="field2"><input type=text name=p_value>
<input type=hidden name=p_name value="field3"><input type=text name=p_value>
<input type=hidden name=p_name value="field4"><input type=text name=p_value>
.....
<input type=hidden name=p_name value="fieldN"><input type=text name=p_value>

Then, have a pl/sql routine like:

create or replace procedure foo( names in owa.vc_arr, values in owa.vc_arr ) is
begin

	for i in 1 .. 100000 loop
		htp.p( names(i) || ' = ' || values(i) );
	exception
		when no_data_found then exit;
	end loop;

end;
/

pass the 'names' in the names array, put the 'values' in a values array..... that value the value of the i'th parameter is values(i) and it's name is names(i)....

On Fri, 07 Feb 1997 10:19:57 +0100, Daniel Pinyol <dpinol_at_cesca.es> wrote:

>Hi,
> Imagine you generate dinamycally a variable number of
>input text fields in a HTML form, from a PL/SQL procedure.
>Each field is a ROW from a table. No problem.
> But if you want to retrieve the input values, it gets
>dodgy. The procedure to be the ACTION of the form must have a
>constant number of argument, musn't it?
> I know you can define the procedure with the forecasted
>maximum number of arguments, but this is not feaseble in my case,
>since I'm displaying lots of fields (about 10 lines, 6 fields in
>each line).
>
> Is there any way that I get the data like this:
> arg1=val1&arg2=val2....
> in a single parameter and then I parse it myself?
>
> Thanks to all.
> Dani
>P.S. I'll appreciate an email to dpinol_at_cesca.es
>
>
>-----------------------------------------------------------------------
> 4 Daniel Pinyol Laserna E-Mail: dpinol_at_cesca.es
>-----------------------------------------------------------------------

Thomas Kyte
Oracle Government
tkyte_at_us.oracle.com                          

http://govt.us.oracle.com

  • Check out Oracle Governments web site! ----- Follow the link to "Tech Center" and then downloadable Utilities for some free software...

statements and opinions are mine and do not necessarily reflect the opinions of Oracle Corporation Received on Sat Feb 08 1997 - 00:00:00 CET

Original text of this message