Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Supporting table structure changes in JPA/Eclipselink
Supporting table structure changes in JPA/Eclipselink [message #1793198] Wed, 01 August 2018 12:53
Javed Shaikh is currently offline Javed ShaikhFriend
Messages: 1
Registered: August 2018
Junior Member
I'm fairly new to JPA/Eclipselink and facing a problem which is in 2 parts - First - I needed to add CLOB field my existing table. I made the required change to persistence classes and it worked with MySQL as database without changing the below property:

<property name="eclipselink.ddl-generation" value="create-tables"/>
However on a DB2 database it does not work that way and had to change it to :

<property name="eclipselink.ddl-generation" value="drop-and-create-tables"/>

I realized that this is not going to work on the production environment running DB2 and I'm not sure whether there is any support within JPA/Eclipselink to support creation of the column without deleting the rest of the data.

Second - A CLOB or LOB field is not treated the same way on a DB2 as it is on MySQL. Althought it generated the requisite SQL script for the DB2 database when I deployed my application it looks like it wasn't enough (DB2 requires more than just a field declaration for a CLOB column - it seems ROWID, tablespace and a few more things are needed). Does JPA support this? If there isn't can I provide additional actions through JPA post deployment for running a script?

Any help with the above would be awesome.
Previous Topic:How to use static metamodel from dependency project/library?
Next Topic:Eclipselink support
Goto Forum:

Current Time: Mon Jan 30 06:24:27 GMT 2023

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

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

Back to the top