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 -> Delete with pameters

Delete with pameters

From: Rami Huhtala <ramirez134_at_hotmail.com>
Date: 29 Nov 2001 00:31:41 -0800
Message-ID: <ac1562ed.0111290031.595437f4@posting.google.com>


I Have A Form where you can select which names you want to delete: CREATE OR REPLACE procedure REMOVE1
AS
AS
CURSOR csr IS

   SELECT NAME,ID
   FROM TABLE
BEGIN
htp.formOpen('remove2');   

FOR trec IN csr LOOP

htp.p(trec.name);
htp.p(trec.id);
htp.p('<input type="checkbox" name="remove_value" value="'||trec.name||'">');
htp.br;

END LOOP;
htp.formSubmit();
htp.formClose;

AND I have procedure that will remove selected items

CREATE OR REPLACE procedure REMOVE2
(
remove_value owa_text.vc_arr,
)
BEGIN
FOR i IN 1 .. remove_value.count LOOP
DELETE FROM TABLE WHERE NAME = remove_value(i); END LOOP; Now I send only name field to the procedure, but what I have to do that I can send also ID field and delete compination match?

I have try these without success:
FORM
htp.p('<input type="checkbox" name="remove_value" value="'||trec.name||' AND ID = ||trec.id">');

PROCEDURE
DELETE FROM TABLE WHERE NAME = remove_value(i);

Problem with this is that it try find NAME = "name_value and ID = id_value" match

Hope You Understand what I Mean
Rami Huhtala Received on Thu Nov 29 2001 - 02:31:41 CST

Original text of this message

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