2

I am developing JSF applicationi with JPA using EclipseLink as the persistence provider using Netbeans. The default version of EclipseLink is 2.0 with Netbeans 7.1, but I badly need the new addition of create-or-extend-tables for eclipselink.ddl-generation which was introduced with 2.4 http://wiki.eclipse.org/EclipseLink/DesignDocs/368365. So I want to add EclipseLink 2.4 to my existing netbeans project, but failed. I followed How do you use EclipseLink 2.3 as persistence provider in NB 7? , but there was no success.

I downloaded the EclipseLink 2.4.0 Installer Zip (28 MB) from http://www.eclipse.org/eclipselink/downloads/index.php. There were several jar files in few folders after I unzip it, but I added only the eclipselink.jar file (with out a version number, which was found in jlib folder) to the Netbeans project libraries.

I tried to add a New Library under persistence.xml also, still failed.

I manually added the code

<property name="eclipselink.ddl-generation" value="create-or-extend-tables" />

to persistence.xml file, but tables are deleted, but not created.

How can I add the latest EclipseLink version to a Netbeans project?

Community
  • 1
  • 1
Buddhika Ariyaratne
  • 2,339
  • 6
  • 51
  • 88

1 Answers1

9

This is how i got lucky

  1. Download the eclipselink 2.4
  2. In Netbeans 7 remove the previous eclipselink jars from Project > Properties : Libraries
  3. Add the new eclipselink.jar as "compile" library and eclipse-jpa-modelgen as "processor".

You will find these libraries in eclipselink/jlib and eclipselink/jlib/jpa

-- persistence.xml

value="create-or-extend-tables"

Uzman Salim
  • 106
  • 1
  • 3