Using EclipseLink to verify tables existence

View: New views
3 Messages — Rating Filter:   Alert me  

Using EclipseLink to verify tables existence

by Krohn :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I have a database which is accessed by old client/server apps besides JPA/EclipseLink. My JPA app can't update database schema. How can I use EclipseLink to just report schema inconsistences with my entities? I want to write an app that reports a system administrator tables and columns missing.

Any ideas?

Re: Using EclipseLink to verify tables existence

by Shaun Smith :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

The Dali Java Persistence Tools project does compare the classes in a persistence unit with a target schema and reports inconsistencies.  Dali is a JPA design time tool but it should be possible to leverage Dali functionality to build a tool that simply reports the information you're looking for.   Dali also supports advanced EclipseLink mappings and configuration validation.

I suggest posting about this on the Dali newsgroup: http://www.eclipse.org/newsportal/thread.php?group=eclipse.technology.dali
   
--Shaun

Krohn wrote:
Hi,

I have a database which is accessed by old client/server apps besides
JPA/EclipseLink. My JPA app can't update database schema. How can I use
EclipseLink to just report schema inconsistences with my entities? I want to
write an app that reports a system administrator tables and columns missing.

Any ideas?
  

--
Oracle
Shaun Smith | Principal Product Manager
Phone: +19055023094
Oracle Server Technologies, Oracle TopLink
ORACLE Canada | 110 Matheson Boulevard West, Suite 100, Mississauga, Ontario | L5R 3P4

Green Oracle Oracle is committed to developing practices and products that help protect the environment



_______________________________________________
eclipselink-users mailing list
eclipselink-users@...
https://dev.eclipse.org/mailman/listinfo/eclipselink-users

Re: Using EclipseLink to verify tables existence

by James Sutherland :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

You can use the IntegrityChecker in EclipseLink for this, you will need to configure it using a SessionCustomizer,

See,
http://www.eclipse.org/eclipselink/api/1.1.1/org/eclipse/persistence/sessions/Session.html#getIntegrityChecker()

checkDatabase()  will make it check the mappings against the database.

Krohn wrote:
Hi,

I have a database which is accessed by old client/server apps besides JPA/EclipseLink. My JPA app can't update database schema. How can I use EclipseLink to just report schema inconsistences with my entities? I want to write an app that reports a system administrator tables and columns missing.

Any ideas?