We need to insert and update BLOB Images in Oracle Apex through PL/SQL process without using default Create and Apply Changes buttons. Step by step Help and guidance is required P.S. 1. We do not want to add directory 2. We use row id as Primary Key.
Share
For that, I am looking for a solution to insert blob data manually, without submitting the page using PLSQL, APEX_APPLICATION_TEMP_FILE works only when you submit the page.
Yes, that is right. I will look for the solution and will update you if I found it.
Thanks,Vinish, for the quick response and support.
In case I find any solution, I will put down here.
Thanks,
There is no issue if you have multiple forms on a single page.
Multiple forms will have multiple processes on the process tab.
When you save, all processes will execute.
You can do the same thing by writing processes instead of multiple dynamic actions, and on-page submit it will do the same task as the dynamic action is doing.
Or can you explain why you are not able to use the page submit because of multiple forms? What issue are you facing?
I have a report with a form of employee details.
so to update the employee details, we click on the edit icon of the report.
And it opens a page having employee form where we can perform DML.
EMPLOYEE FORM: https://drive.google.com/file/d/1ABxSvn8hYHYg_ut95FDLaXIglvgXoL97/view?usp=sharing
I have created another form for entering documents details for that particular employee on the same page.
Though separate processes are being created for each form.
I have also configured a specific form region for Form-Auto. Row. Process for the documents.
and save button to perform database insert on page submit for docments.
It gives an error that empoyee_id constraints are violated.
and this suggests that the employee form is performing an insert, not the document.
DOCUMENT FORM: https://drive.google.com/file/d/1dZiYYk3dP99fZpEQVyygNnI_LshLA9Bl/view?usp=sharing
Ok, your issue is, how to identify that the insert is happening or update, because the process will run according to the button assignment.
So if you have multiple forms, then you have to change your UI, I mean instead of the display region, use Tabs and create two sets of buttons Create and Update for every form in Tab.
And these buttons will be displayed according to the server-side condition based on the PK value.
Now you will have to run the every process on specific buttons only. For example, you will set a particular process as below:
Server-side condition:
Request contains in the value:
Create_EMP_Button,Update_EMP_Button
Suppose you have an EMP form, containing two buttons for insert and update, then its DML process will run only when these buttons will be clicked.
And only one button will be visible at a time due to the PK server-side condition.
You getting my point?
No Sir I Want How To Save Blob Like
Set the source type for your file browse item to Table APEX_APPLICATION_TEMP_FILES.
Then create a process which will run after submitting the page and add the following PL/SQL code in it:
Change the item names according to your page items.
Hi Vinish,
I am able to insert records using dynamic actions without submitting the page but having issue in the blob data.
Can you please share how we can insert blob data using dynamic action without submitting the page.
Thanks in advance!
If you are trying to insert the Filebrowse item using the dynamic action, then you will face issues.
Try to write a process instead and create a button to submit the page so that blob can insert using the process.
Hi Vinish,
Thanks for the quick response.
Actully I have multiple forms in a single page: I am using Region Display Selector, that is why I am using dynamic actions to insert/update records for each form.
So I can not submit the page, It submits the records from another tab. And create issue.
Meaning, you want to save immediately after uploading the image file without clicking on any button?
If so, then you can create a dynamic action on the file browse item and select the event Change. Set the action Submit page.
That is all; now, when you will upload an image immediately after the page will submit, and the default form process will run, and your changes will be saved automatically.
If you have something different requirement, then please explain what kind of form page you want to develop?