The steps in this section add a radio button group to the insert.jsp page, which enables a user to choose between inserting an employee record using the stored procedure, or by using a SQL query in Java code.
insert.jsp in the Visual Editor, if it is not already open.jsp:useBean tag to the page. Enter empsbean as the ID, browse to select hr.DataHandler as the Class, and set the Scope to session. With the UseBean still selected on the page, set the style of this line to None instead of Heading 3.useSP as the Name, false as the Value, and select Checked. Click OK.useSP as the Name, true as the Value, and ensure that the Checked check box is not selected.Figure 6-1 shows insert.jsp with the radio button that provides the option to use a stored procedure.
Figure 6-1 Adding a Link to Provide the Stored Procedure Option
