From:       To:      
Home > Documentation > MySQL to Oracle

Command line version of MySQL to Oracle converter

To perform batch conversion or call the conversion procedure from an automation script you can use console version of MySQL to Oracle converter. This is the file S2OAGENT.EXE in the installation folder. You can either run this tool directly from command line or call it from any script as well. The program supports the following command-line options:

--blob2text   convert BLOB to text
--dest=...   Oracle service name
--help   display help message and exit
--logfile=...   path to the logfile where execution traces will be written
--mode=...   how to process tables that already exist in Oracle database
(0 - overwrite, 1 - merge, 2 - skip)
--mysqlh=...   MySQL server IP address or network name
--mysqlu=...   MySQL user name
--mysqlp=...   MySQL user password
--oraclu=...   Oracle user name
--oraclp=...   Oracle user password
--port=...   MySQL port
--silent   use this option to disable program output
--skip_idx   skip converting indexes
--src=...   MySQL database name
--tab_def   convert table definitions only
--tab_file=...   name of the file containing table names to convert (one table name per line)
--uppercase   make names uppercase

In the following example the program converts MySQL database "db1" on the remote MySQL server "mysqlhost" into Oracle database "db1_from_mysql":

S2OAGENT.EXE --src=db1 --dest=db1_from_mysql --mysqlh=mysqlhost 
             --mysqlu=administrator --mysqlp=the_passsword 
             --oraclu=scott --oraclp=tiger

Table names file should be formatted as follows: