Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Eclipse link and db description in xml
Eclipse link and db description in xml [message #724774] Tue, 13 September 2011 06:47 Go to next message
Vaclav Tuma is currently offline Vaclav TumaFriend
Messages: 7
Registered: April 2011
Junior Member
Hello,
I use eclipselink for few time, and I have experiences only with generating persistence entities from database. But is somehow possible to generate persitence entities from other description nor database - for example from description of database - xml typed description.

Reason why I ask (whole idea) is following:
database is descripted in sql - but if I have db schema description for example in xml (.. it could be liqui base format - or other format, ... better if the format could be customable and allows to have additional information), I could transform xml to sql and then run it or get additional information. All descriptions of one "domain" is together and changes could be simply versioned (with cvs, svn, mercurial..).

Is something simillar supported with JPA (eclipselink)?

Thanks Wink


Re: Eclipse link and db description in xml [message #724877 is a reply to message #724774] Tue, 13 September 2011 12:02 Go to previous messageGo to next message
Gordon Yorke is currently offline Gordon YorkeFriend
Messages: 78
Registered: July 2009
Member
Have you looked at orm.xml? That is JPA defined xml metadata used to describe mappings to database. Using the orm.xml EclipseLink can then generate the DDL scripts to drop and create the database.
(no subject) [message #724880 is a reply to message #724774] Tue, 13 September 2011 12:02 Go to previous messageGo to next message
Gordon Yorke is currently offline Gordon YorkeFriend
Messages: 78
Registered: July 2009
Member
Have you looked at orm.xml? That is JPA defined xml metadata used to describe mappings to database. Using the orm.xml EclipseLink can then generate the DDL scripts to drop and create the database.
Re: (no subject) [message #725049 is a reply to message #724880] Tue, 13 September 2011 19:35 Go to previous message
Vaclav Tuma is currently offline Vaclav TumaFriend
Messages: 7
Registered: April 2011
Junior Member
I don't use mapping via orm.xml. Correct me if Im wrong, but I thought that orm.xml just describe the same what is in persistent object mapped with annotation. And generating could be switch on/off in eclipse link setting.
The point of question was more focused on idea if entities could be generated from another source nor database.
.. but, thanks for reply and idea Wink
Previous Topic:(no subject)
Next Topic:ManyToMany relation DELETE
Goto Forum:
  


Current Time: Tue Apr 23 09:28:26 GMT 2024

Powered by FUDForum. Page generated in 0.02546 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top