Re: Committing during a schema synch
Re: Committing during a schema synch
- Subject: Re: Committing during a schema synch
- From: Chuck Hill <email@hidden>
- Date: Wed, 23 Aug 2006 09:55:21 -0700
On Aug 23, 2006, at 4:46 AM, Aaron Rosenzweig wrote:
Hi WOFriends,
I'm pretty far along on a Firebird EOModeler plugin. It appears to
be outputting all the right sql statements for a synchronization.
But I have a problem.
I need it to commit after a table is created and probably also
after a table is dropped. If I just tell EOModeler to execute, it
will fail at points where it can't "see" the table it created
previously. When I cut and paste the synchronization code into a
sql client and execute it there, I get the same thing. When I add
commit statements by hand and execute it on the sql client, it
works famously.
Any tips on how to best implement this is appreciated.
If this helps, there is an NSArray of SQL expressions generated by
this method in the API:
statementsToUpdateObjectStoreForModel()
If anyone knows where this called, and how I could override things
to just simply do a commit after each expression, I believe that
would be a quick and dirty way to get this to work.
You could put the commit statements inline in the statements returned
by that method. Also, check to see if FireBird supports auto-commit
for a connection. You could connect in auto-commit mode.
Finally, EntiyModeler in WOLips may provide better support for this
sort of tweaks. It might also be a better long term bet.
Chuck
--
Practical WebObjects - for developers who want to increase their
overall knowledge of WebObjects or who are trying to solve specific
problems. http://www.global-village.net/products/practical_webobjects
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden