Add Persistence to the Project |
Use this procedure to add persistence to the Employee project.
Right-click the Employee project in the Explorer and select Java Persistence > Add Java Persistence. The Add Persistence Dialog appears.
On the Add Persistence Dialog select a database connection that you created earlier (see "Create a Database Connection") and click Finish.
You must be connected to the database before adding persistence to the project.
You can now work in the Persistence Perspective. From the menu bar, select Window > Open Perspective > Other. The Select Perspective dialog appears.
Select Persistence and click OK. The Persistence Outline and Properties views appear.
The next step is to Create Java Persistence Entities.