checkbox values [message #225628] |
Tue, 20 March 2007 11:01 |
Fury22
Messages: 1 Registered: March 2007
|
Junior Member |
|
|
Hi everyone.. I have a problem with the checkbox .. I'm trying to add to another checkbox item values according to the values previously selected in other checkbox.
For example..
If I check
--pizza (checked)
--Taco (checked)
--Ice Cream
I want the other checkbox get filled with all the data from those 2
I mean... make a "select desciption where food_id IN (values of the checkbox---> pizza and taco)"
Please help me
|
|
|
Re: checkbox values [message #225728 is a reply to message #225628] |
Wed, 21 March 2007 02:46 |
rleishman
Messages: 3728 Registered: October 2005 Location: Melbourne, Australia
|
Senior Member |
|
|
Sorry, don't have much time to answer now...
If I remember correctly, the value of the checkbox item will be a colon separated list of checked values. Eg. If Pizza and Taco were coded 3 and 8 respectively, the value of the item would be "3:8".
You need to convert this to a nested table - you can use APEX_UTIL.STRING_TO_TABLE, but this returns a PL/SQL nested table which you cannot use in a SQL. You will need to create your own database nested table TYPE or perhaps a Global Temporary Table and copy in the values from the PL/SQL nested table. You will then be able to reference this in an IN subquery.
It's a bit complex, I know. Sorry I don't have more time - I've got to go home now.
Ross Leishman
|
|
|