-
1. Also with only cascade delete in the entity model it does no
thuesler Dec 8, 2003 4:32 AM (in response to thuesler)Hi
I now gave it a trial to remove the cascade delete specs on the DB and only having them in the CMP Model. Also this does not work.
The DB now states a fk constraint violation that there are still child rows existings... Seems to me as the whole cascade delete logic does not work in JBOSS 3.2.1... Anyone having a clou if it is a bug?
t -
2. Re: Also with only cascade delete in the entity model it doe
juha Dec 8, 2003 7:27 AM (in response to thuesler)Sounds like it is just your database constraints conflicting with what the CMP engine is attempting to do.
Either specify cascade-delete in the database and don't do it at EJB level or specify it at the EJB level and set the DB constraints to such that the CMP engine is allowed to delete the rows in its own order (which seem to violate your current DB schema referential integrity).
-- Juha -
3. Re: Error removing Entity with cascade delete specified
thuesler Dec 12, 2003 2:44 AM (in response to thuesler)With the customer we're having it will be fairly difficult to get the database setup so that application Keys can be set null what seems to violate Jboss...
So I am actually using the db cascade deletes. But what happens if the JBoss runs in a cluster??? Is it working with db cascade deletes? -
4. Re: Error removing Entity with cascade delete specified
juha Dec 12, 2003 8:18 AM (in response to thuesler)What is the issue with cascade-delete on a cluster? Please explain.
-
5. Re: Error removing Entity with cascade delete specified
gorano Dec 16, 2003 10:31 PM (in response to thuesler)My solution was to just disable all my DB-constraints and now JBoss works fine with cascade delete.
But to be honest, I think the JBoss implementation of the cascade delete should follow the "common sense" logic to delete the children first and then deal with the parent.
But I'm probably wrong ;-) maybe there is some good reasons not to follow the most logical way of dealing with cascade deletes.
goodnight
Goran