问题
I used Interactive report APEX_ITEM.CHECKBOX2(p_idx => 1, p_value => ST.ID, p_attributes => DECODE(ST.IS_HEADER_ROW ,'Y', 'DISABLED',NULL)). And I want to use highlighted IDs depending upon checks in Row ID field in Comma delimited format DYNAMICALLY.
Further I will use that Row IDs value in another region report and will update values in DB after few validations.
回答1:
On button press, you could run this JavaScript which concatenates all nominated checkboxes into a delimited string.
$s('P1_ROWIDS',
$("[name='f01']").map(function(){
return this.value;
}).get().join(",")
);
Then use the following query to find all the records matching values in that string using this, or your version's equivalent.
select * from your_table
where id in (select column_value from apex_string.split(:P1_ROWIDS))
This can all happen without submitting the page.
回答2:
Below code will fetch only those IDs which are checked in checkbox in comma delimited format (Note: this can be included in DA on any button which should be clicked after selection of multiple rows via checkbox)
$s('P11_ROW_PK', $("[name='f01']:checked").map(function(){ return this.value; }).get().join(","));
来源:https://stackoverflow.com/questions/63618493/through-apex-item-checkbox-checks-want-to-store-values-in-item-field