• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Easy way to convert mySQL database to postgreSQL?

LeetestUnleet

Senior member
Ugh... I design a whole website with mySQL databases at the core of it, then when it comes time to upload it to the client's chosen host, the host only supports postgreSQL and not mySQL. It's VERY tedious to convert it all by hand, especially since it's a rather large introductory database. So I was wondering if anyone here knew of a utility that could just do a clean conversion? Preferably would input a .sql or .txt file and output it the same?
 
you could use something like phpMyAdmin to dump the mysql database to SQL and then load that file into pg. things *should* work although you may have problems if you have anyting mysql-specific in there (like table types or field types)

you may want to google around on converting mysql SQL to pg SQL
if you stick to standard sql statements, you should be fine. guess it looks like you should have thought about database abstraction. PEAR is your friend
 
Yeah, my problem was at first the field types in the tables, but I fixed those. Now the syntax for some input data is going to be messy, since a bunch of " has to be replaced with ', some other things have to be escaped with a \, etc and other stuff like that. I was hoping someone, somewhere had figured out how to do it easier :S
 
Back
Top