Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I've been tasked with migrating a fairly complex legacy Sybase database into a MySQL database and I have no idea where to start. I can't use any off the shelf software, so I'm going to have to write some sort of script that takes all the info out of the Sybase database and puts it into MySQL. Does anyone have any resources or thoughts on how to do this quickly, as I have very little experience with Sybase or MySQL.

share|improve this question

closed as too broad by Mark Storey-Smith, Jon Seigel, Mat, dezso, Max Vernon Aug 7 '13 at 16:06

There are either too many possible answers, or good answers would be too long for this format. Please add details to narrow the answer set or to isolate an issue that can be answered in a few paragraphs.If this question can be reworded to fit the rules in the help center, please edit the question.

1  
What are cots? –  a_horse_with_no_name Mar 28 '13 at 14:49
    
Commercial off the shelf product. So like I need to write it in house. –  Grammin Mar 28 '13 at 14:50
    
You should edit your question to say "off the shelf software" instead of cots.... –  Max Vernon Mar 28 '13 at 14:56
    
It helps to know what product and version of db you are using, since Sybase is a company, not a database. –  Michael Gardner Mar 29 '13 at 13:08
    
I don't mean this to be insulting, but if you have very little experience with Sybase or MySQL then why have you been tasked with this? A migration is a nontrivial task that requires expertise in both source and destination database products. –  Greenstone Walker Aug 7 '13 at 1:31

2 Answers 2

Having no experience with Sybase, I suppose I would start by exporting the database schema into a text file, then go through and modify the CREATE TABLE statements manually until I am able to load the schema into MySQL.

Next, dump the data from each sybase table into CSV format file and then in the MySQL database, use LOAD DATA INFILE.

Depending on your database size, this could be a painfully slow option, but it is 'easy'.

share|improve this answer

You can use the Sybase utility ddlgen to export the database structure, schema, objects, etc. from there you will have to go through the script files that are generated, and figure out what will run and what won't run.

Data can be exported by using the Sybase bcp utility, with whatever delimiters are necessary to import into your new database.

Both of these utilities are part of the Sybase installation, so they should be available for your use.

My answer here has more information on running ddlgen and bcp Sybase Databse Migration from 11.5 to 15

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.