Oracle APEX Shuttle : How to do it?
In this post, I will talk about storing the multiple values into Oracle database in a way of storing the value one by one. Meaning that, if there are 4 active selection, the operation will be storing or insert the 4 value into Oracle table each row. So there will be 4 insert operation will be executed.Please check below code:
declarePlease note that :PX_YOUR_ITEM is referring to your Shuttle Item name.
tab apex_application_global.vc_arr2;
begin
tab := apex_util.string_to_table (:PX_YOUR_ITEM);
for i in 1..tab.count loop
insert into YOUR_TABLE (YOUR_COLUMN_NAME, YOUR_SHUTTLE_COLUMN_NAME)
values
('My List', tab(i) );
end loop;
end;
Where should I put those code?
1.Page Processing > Processing > Process, right click > Create
2.Select PL/SQL and you may procees the rest
3.When you see 'Enter PL/SQL Page Process', paste the code here. Please change accordingly follow your item page name and table/column in your database.