I'm trying to build a tabular form, with a checkbox for a field that can have value 'Y' or 'N'. Adding the checkbox is no problem, with the htmldb_item.checkbox API.
However, processing it is.
On this forum I found a way to process the checkboxes, by looping through all the records (with the help of htmldb_item.hidden in which the id is stored) and reading the value from the checkboxes and updating the column if the checkbox is checked. (see
this thread)
however, as soon as I add a htmldb_item.hidden item, I receive the following error when I submit the tabular form to the Multi Row Update process:
"Error in mru internal routine: ORA-20001: Error in MRU: row= 1, ORA-20001: ORA-20001: Current version of data in database has changed since user initiated update process. "
My query:
Select id
,htmldb_item.hidden(1,id)
,htmldb_item.checkbox(2,id, decode(field, 'Y', 'CHECKED', NULL))
from table
What am I doing wrong?
is there a better way to process a tabular form with checkboxes?
Or should I process all the rows manually by updating every record even if it hasn't changed (with a loop through all the records)?