views:

439

answers:

1

how to add jpa support for existing maven project

i tried

project-->configure--> convert to jpa project (there is no this option)

but for my other projects, such option available... can comment?

I already have existing mven project and i want to generate jpa entity from tables. no need to create new jpa project right?

A: 

I'm not sure but I think that you need to setup your project to use the JPA Facet (right click on the project the Properties > Project Facets and select Java Persistence). I don't know if m2eclipse can add this facet automatically.

But actually, with the version of Eclipse I'm using, adding the JPA facet doesn't add any entry for JPA under Configure when I right click on a project. It adds a menu JPA Tools > Generate Entities from Tables... (and JPA Tools > Generate Tables from Entities...).

Pascal Thivent