Home » Developer & Programmer » Application Express, ORDS & MOD_PLSQL » How do you refer to value in a Select list
How do you refer to value in a Select list [message #384294] Tue, 03 February 2009 03:09 Go to next message
Derek N
Messages: 80
Registered: September 2002
Member
Hi

I have a select list named P1_prod.

My definition of the select list is:

SELECT product_name d, id r FROM products ORDER BY 1;

I created a validation. How do I refer to the product id from the select list. :P1_prod.id does not seem to work.

Thanks
Re: How do you refer to value in a Select list [message #384305 is a reply to message #384294] Tue, 03 February 2009 03:40 Go to previous messageGo to next message
dr.s.raghunathan
Messages: 540
Registered: February 2008
Senior Member
your attempt will not work. You would have selected the selected list of P1_prod ( using select list / lov and pressing the enter) against the page variable and stored the return value. where is the question for further reference for validation using the prodlist name.
Re: How do you refer to value in a Select list [message #384318 is a reply to message #384294] Tue, 03 February 2009 04:45 Go to previous messageGo to next message
Derek N
Messages: 80
Registered: September 2002
Member
Are you saying that I should use the product name and not the id in my validation?

Thanx
Re: How do you refer to value in a Select list [message #384338 is a reply to message #384318] Tue, 03 February 2009 07:33 Go to previous messageGo to next message
c_stenersen
Messages: 255
Registered: August 2007
Senior Member
If you want to do the validation based on the id, simply use :P1_prod.

The item will always contain the return value of the select list (id in your case). The display value is not what you refer to, it's only shown in the select list, not stored in the item. :P1_prod is stored as a simple value, not a record of some sort.
Re: How do you refer to value in a Select list [message #384354 is a reply to message #384294] Tue, 03 February 2009 08:44 Go to previous message
Derek N
Messages: 80
Registered: September 2002
Member
Thanks, would try and let you know.
Previous Topic: Display value in text field
Next Topic: Mailto url and page items
Goto Forum:
  


Current Time: Mon Dec 05 18:44:14 CST 2016

Total time taken to generate the page: 0.25791 seconds