DBReplicate

Simplify Interbase->PostgreSQL conversions

I wrote a Perl program to help my company migrate from Interbase to PostgreSQL by extracting a database's data and metadata and dumping it as a set of SQL commands (similar to pg_dump or mysqldump).

I wrote the program originally to do a row-level backup of our Interbase databases. We had a few that were corrupted, and the standard tools were unable to extract data from them without segfaulting, so I came up with this to scavenge as much information as possible from the failing databases. Recently, I convinced my company to dump Interbase in favor of PostgreSQL (yay!), but we host about 20 websites, each with databases in the hundreds of thousands of rows, and we weren't looking forward to the data transfer at all. I happened to remember this program, made a few modifications, and came up with something that Works Good Enough For Now.

My boss was gracious to let me release this under the terms of the GPL (thanks, Don!), so feel free to mangle it to your heart's content.

Please, please, PLEASE note that this was never written to be the end-all be-all of database conversion utilities. It's simply the solution to a problem that we had, and written with the needs of my company in mind. I hope that someone else can use it, but it may turn out to be worthless for anyone but us.

It supports:

  • Full exporting of all data and metadata in a database.
  • A rudimentary mechanism for re-writing datatype names (a simple one-way Perl hash).
  • Support for converting Interbase auto-incremement triggers to PostgreSQL SERIAL fields, including setting the current value at the end of the process.
  • Basic generator re-writing

Releases

Official releasesDateSizeLinksStatus
1.92008-Mar-284.56 KBRecommended for allThis is currently the recommended release for all.


Does this work for Firebird 2.0?

Does this work on Firebird 2.0 databases?

Thanks, Zak

I don't know. That depends

I don't know. That depends entirely on how well the output of isql from Firebird 2.0 matches the output of isql from Interbase.

Post new comment

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <blockquote>
  • Lines and paragraphs break automatically.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
one times five equals
Solve this math question and enter the solution with digits. E.g. for "two plus four = ?" enter "6".

Powered by Drupal - Modified by Danger4k