Re: import mysql dump file

From: onedbguru <onedbguru_at_yahoo.com>
Date: Thu, 18 Nov 2010 16:26:36 -0800 (PST)
Message-ID: <27f9540f-099f-428b-b4c6-961f6e94bc5e_at_m35g2000vbn.googlegroups.com>



On Nov 17, 9:24 am, Mark D Powell <Mark.Powe..._at_hp.com> wrote:
> On Nov 17, 8:35 am, syd_p <sydneypue..._at_yahoo.com> wrote:
>
>
>
>
>
>
>
>
>
> > On 16 Nov, 23:49, Enrico 'Henryx' Bianchi <henryx.b_INVA..._at_libero.it>
> > wrote:> syd_p wrote:
> > > > Any ideas?
>
> > > You can use --compatible=oracle with mysqldump (the result is not assured)
>
> > > Enrico
>
> > Thanks -Tried that - sqlplus did not like the result tho.
>
> > Also I installed the latest version 4.1.1 Oracle sql developer
> > Tools-Migration-Third Party Database Offline Capture-Create Database
> > Capture Scripts
>
> >  And I craeted some scripts for linux  (get_col_table_5.sh
> >  get_max_col_5.sh      get_table_5.sh
> >  get_constraint_5.sh  get_stored_proc_5.sh  master_5.sh)
> >  invoked master_5.sh with user password and hostname
> >  amd got some sql files:
> >  all_cols_tabs19675.sql  showdatabases.sql
> >  temp_constraints_tabs19675.sql  temp_showtabs19675.sql
> >  routines_name19675.sql  showviews19675.sql
> >  temp_routines_def19675.sql      version19675.sql
> >  routines_name2444.sql   showviews2444.sql
> >  temp_show_cols_tabs19675.sql    version2444.sql
>
> > +  some xml files
> > +  a mysql5.ocp file
>
> >  But I dunno what the next step is - anyone can help with that plz do.
> >  -Syd
>
> Check to see if the Oracle migration workbench supports mySQL to
> Oracle conversion.  If it does and you have access to the mySQL
> database this tool may be of use.
>
> If you have access to the mySQL database you might just want to
> extract the data into delimited data files and then use sqlldr to load
> it.  This would require creating Oracle DDL to create the objects but
> it is one possible approach.
>
> HTH -- Mark D Powell --

These tools do little to nothing to convert things like auto-increment columns into something Oracle will recognize and more often than not, the procedures include mysql only functions. Auto-increment will need to be addressed using an insert/update trigger and a sequence.

using this will dump the schema info and you can use your favorite editor (prerferably NOT notepad) to clean it up: mysqldump database –no-data=true –routines=true > outputfile.sql

Then you can use SQLDEVELOPER to move the data. You will need to initially be worried about any referential integrity and take the appropriate measures to ensure everything stays the same.

You will not get out of this effort as easily as you may have liked... Been there, done that, have the T-shirt. Received on Thu Nov 18 2010 - 18:26:36 CST

Original text of this message