Creating an entity bean
In this section, we create an entity bean from the database table CATALOG
. Select the Model project node in the Application navigator. Select File|New. In the New Gallery window select Business Tier|EJB in the Categories and select Entities from Tables in Items. Click on OK.
As discussed in some of the earlier chapters, in the Persistence Unit window, click on New to create a new persistence unit. Specify the persistence unit Name as em and specify JTA Data Source Name as jdbc/OracleDBConnectionDS. Select WebLogic Server 10 as the Server Platform. Click on OK. Click on Next in the Persistence Unit window. In the Type of Connection window, select Online Database Connection and click on Next. In Database Connection Details, select the OracleDBConnection and click on Next. In Select Tables, select the OE Schema and select the Auto Query checkbox. Shift the CATALOG table from the Available to the Selected list and click on Next. In General Options, specify the Package...