Live data from Hacker News

MySQL to PostgreSQL converter

github.com

11–20 of 37 posts

Re: MySQL to PostgreSQL converter

#11
We were getting really close to converting our RDS instance from MySQL -> PG, but now with Amazon Aurora being the spiffy super-scalable/etc. RDS engine, we'll probably end up moving to that when/if needed.

Which is a mixed blessing; Aurora sounds great, but I was looking forward to getting back into PG after years of RDS being MySQL-only.

Re: MySQL to PostgreSQL converter

#16
post #15

A big problem I've encountered was MySQL-specific functions used in client code. Fortunately there was a project that reimplemented many of these functions in Postgres: https://github.com/pornel/mysqlcompat

There was but the last commit is from 2011?

Re: MySQL to PostgreSQL converter

#17
post #16
post #15

A big problem I've encountered was MySQL-specific functions used in client code. Fortunately there was a project that reimplemented many of these functions in Postgres: https://github.com/pornel/mysqlcompat

There was but the last commit is from 2011?

That's when I've migrated ;)

The code is even older, but fortunately the most common MySQL functions haven't changed in maybe a decade.

Re: MySQL to PostgreSQL converter

#18
post #12

When I saw this was a PHP project: https://dl.dropboxusercontent.com/u/31250/gifs/no-thanks.gif

Really? What does the language it's written in have to do with anything at all here?

Here it actually matters a bit. The pgloader project was rewritten in Common Lisp from the original Python version to speed up processing the data. You want to be able to migrate terabyte databases without too much downtime.

Re: MySQL to PostgreSQL converter

#19
post #16
post #15

A big problem I've encountered was MySQL-specific functions used in client code. Fortunately there was a project that reimplemented many of these functions in Postgres: https://github.com/pornel/mysqlcompat

There was but the last commit is from 2011?

Fork it!

Re: MySQL to PostgreSQL converter

#20
post #7

Earlier quoted context omitted.

Ah. That's a relief, I was a little worried. But that makes it strange that someone, knowing of this limitation, would choose to start with the xml dump format.

I think the fact that this form of dump doesn't contain foreign keys is even more extraordinary. What's the point of having a dump format that you can't use to restore your database properly? Does it have a health warning advising that it's not a proper dump?

It contains the foreign key data, but not the constraint.

You get this:

    
But not this:

    CONSTRAINT `fk_courses_offered_class_details`
    FOREIGN KEY (`course_id`)
    REFERENCES `courses_offered` (`id`)
Post reply on HN