This Steps will help you to create OAF page and Insert data into custom table with who columns into Oracle R12 Application.
Step1: Webui and Server folder is required for building any custom OAF page

Step2: Create EO and EOVO with who columns into Server

Step3: During Creation of EO below SQL statement will generate automatically

Step4: Create Page structure as per your requirement and Page will be under Webui.

Step5: Once you click on AM under Server you will get AM Java file name select AM’s DataDisplayAMImpl.java just double click on that, In that java file create one method for inserting the data.
public void insertData() { /Below code to initialize the VO/ OAViewObject vo = getXXEMPEOVO(); if(!vo.isPreparedForExecution()) { vo.executeQuery(); } /*write the following code to create one empty row */ OARow row=(OARow)vo.createRow(); /Below code to insert the data/ vo.insertRow(row); }
Step6: Create another method for saving the data.
public void Save() { getOADBTransaction().commit(); }
Step7: Create Page Controller under Webui, in controller call above method under ProcessRequest
public void processRequest(OAPageContext pageContext, OAWebBean webBean) { super.processRequest(pageContext, webBean); /*for initializing the AM */ OAApplicationModule am=(OAApplicationModule)pageContext.getRootApplicationModule(); /*invoke the method which u write for inserting data */ am.invokeMethod("insertData"); }
Step7: Write below in Controller under ProcessFormRequest
public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
{
super.processFormRequest(pageContext, webBean);
/*for initializing the AM */
OAApplicationModule am=(OAApplicationModule)pageContext.getRootApplicationModule();
if(pageContext.getParameter("Save")!=null)
{
/*invoke the method which u write for saving the data */
am.invokeMethod("Save");
/* for throwing confirmation message*/
throw new OAException("Data Entered Successfully”, OAException.CONFIRMATION);
}
}
Step8: Run the Page to see the Output

Step9: Query the table to see whether data is inserted into your custome table
