Re: From Oracle to MySql
Re: From Oracle to MySql
- Subject: Re: From Oracle to MySql
- From: Robert Walker <email@hidden>
- Date: Wed, 15 Dec 2004 10:23:04 -0500
I have occasionally needed to move from one db to another. I've not
dealt with Oracle but I have moved between FrontBase, OpenBase SQL, and
MySQL.
I have used the EOModeler's "Switch Adaptor..." to create a MySQL model
from an OpenBase SQL model.
EOModeler actually does a fairly decent job picking the right column
types for the new database. However, I've never been completely happy
with some if it's choices so I manually walk through each attribute of
each entity and "fix" the column types where necessary.
I imagine some WO developer's make use of the prototypes, especially
for this purpose. I've found using them to be a bit dangerous, unless
you're meticulous in their use, given that they make global changes to
the model. This is fine until it makes a change you didn't expect and
your column types get out of sync with the actual database.
After doing this I used EOModeler to create the database tables in
MySQL (for this example).
I have also used BulkMover, which works well, unless you have a large
database with many rows of data. I was getting "out-of-memory" errors
in the JVM. After several attempts at increasing the JVM heap size, I
ended up having to modify BulkMover to filter certain tables and move
the data in pieces. Hopefully you won't run into this. In my case I
had to move a legacy database where some tables contained over three
million rows.
On Dec 15, 2004, at 6:38 AM, Jean-François Veillette wrote:
I have developped an WO application using an Oracle database via an
EOmodel.
Is there a way to get quickly an equivalent EOModel for MySQl ?
Yes, use prototypes. Look at the documentation for EOPrototypes,
EOJDBCPrototypes and the likes.
If you're going to constantly move from one bd to the other, this is
the most practical solution.
What are the equivalent type to use for
VARCHAR2(), DATE, CLOB,NUMBER ...
not sure, look at the doc.
Is there a simple way to migrate the data ?
yes, once you can create 2 models, one model connect to mysql, the
other one connect to oracle, and ask BulkMover to move your data for
you.
BulkMover is a wo app, available on WOCode.
There most likely some other kind of code that would do the trick,
look on freshmeat.net ('jdbcimporter' for example).
- jfv
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden
This email sent to email@hidden
--
Robert Walker
Bennett Technology Group
_______________________________________________
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