[ 
https://issues.apache.org/jira/browse/OPENJPA-1760?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12919027#action_12919027
 ] 

Oliver Bayer commented on OPENJPA-1760:
---------------------------------------

Hi Rick,

thanks for your help and the effort you put into this issue.

Maybe I have to read the spec once again to solve the misunderstanding, sorry 
for the unusable patch. 
I don't know if I get you right but I understand your answer as follows:

- retain: should delete all unknown tables which isn't happening in my testcase
- deleteTableContents: should delete content only from known tables but deletes 
ALL data

So there are now two bugs than only the one I assumed?

I'm sorry to say but I can't agree with the priority of this issue. I don't 
want to say anything against your work (don't get me wrong) but if a 
PERSISTENCE framework accidently remove ALL data it's -if you would ask me- 
nearly a show-stopper.

I would like to help but if you can't fix it quickly on the fly it would take 
nearly months to get a valid bugfix :-).

Nevertheless thanks a lot!
Oli

> SchemaAction='refresh,deleteTableContents' incorrectly removes data from ALL 
> DB tables.
> ---------------------------------------------------------------------------------------
>
>                 Key: OPENJPA-1760
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1760
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: tooling
>    Affects Versions: 2.0.0, 2.1.0
>         Environment: Win XP, Postgres 8.4, OpenJPA 2.0.0 
>            Reporter: Oliver Bayer
>            Priority: Minor
>             Fix For: 2.1.0
>
>         Attachments: OPENJPA-1760_testcase.patch
>
>
> At my usecase not all tables are managed by openjpa so not all of them are 
> listed with the class-tag inside persistence.xml. I set up openjpa to delete 
> the table contents for developping with the following property:
> <property name="openjpa.jdbc.SynchronizeMappings" 
> value="buildSchema(SchemaAction='add,deleteTableContents')"/>
> But now all contents are deleted even the one of tables which aren't listed 
> inside persistence.xml. 
> Shouldn't openjpa only delete contents from tables which are configured plus 
> the openjpa_sequence_table rather than deleting all contents from the whole 
> database? Is this a bug or is there a property which I have to set to get the 
> described behaviour?
> Greets Oli

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to