Chapter No.10 How to save the data in database in Oracle?

In this chapter we will store the data in oracle database.

In Chapter No.6 we have designed a form by using oracle forms builder with wizard.  We will store a data of these fields in database now. As we know that we are already created tables in database in Chapter No. 2.

  1. Open a form in oracle forms builder that we have designed in Chapter No.6 and connect it with database.
  2. Drag a button on canvas.
  3. Click on button and press F4 go to the property of this button and set its label i.e “Save”.
  4. Now we will put a trigger on this button that is “WHEN-BUTTON-PRESSED” trigger.
  5. In order to put this trigger on button just right click on this button and select “Smart Triggers” then select “WHEN-BUTTON-PRESSED” trigger.
  6. Put this code in SQL/PLSQL portion of the trigger.



7. After this code just run this form with shortcut key (CTRL+R).

8. Now your form is ready for use without any error just put the data in these fields and press this button “Save”


  • muhammad yousaf

    hi! that is the best way to learn every thing about oracle and I like too much

  • Sajjad Ahmad

    how to write plsql code for the save button for the many block

    • Dear Sajid,
      You have to make a Master Detail relationship between two tables. Then can use this code for saving the data in multiple blocks. Thx

  • mzahids

    can anyone help me in orcle

  • Muzammil Aslam

    please i need next chapters thanks