Re: MSSQL -> PostgreSQL

From: "Ian Harding" <ianh(at)tpchd(dot)org>
To: <chris(at)upnix(dot)com>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: MSSQL -> PostgreSQL
Date: 2003-05-16 19:36:44
Message-ID: sec4dbcb.058@mail.tpchd.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

MSSQL Server and PostgreSQL are both very SQL standard compliant. If you are only talking about tables and data, this is a relatively easy project regardless of the size of the tables. If you have views, stored procedures, triggers, etc, you may be in for some work, but I doubt you do since you could convert to MySQL.

The suggestions so far (PGAdmin, dump and copy) are both feasible, and there is also the MSSQL Server Data Transformation Services tool (or whatever it's called now) which can talk directly to PostgreSQL via ODBC. I have heard it doesn't know how to convert MSSQL's version of SERIAL to PostgreSQL's, but you could fix that later with ALTER TABLE ... ALTER COLUMN ... SET DEFAULT ....

Good luck! It is worth the effort.

Ian Harding
Programmer/Analyst II
Tacoma-Pierce County Health Department
iharding(at)tpchd(dot)org
(253) 798-3549

>>> Chris Cameron <chris(at)upnix(dot)com> 05/09/03 09:16AM >>>
I'm looking to convert 2 MSSQL DB's to PostgreSQL. I've searched the
archives and various websites and found a number of solutions.

The problem is, none of them work for me. One of the databases is 150
Megs, the other 3 Gigs. It isn't very feasible for me to go into a 3 gig
file and search/replace all sorts of things (which seems pretty "iffy" a
solution to me).

I've also tried converting the MSSQL tables/data to MySQL dumps (we had
a -very- good tool laying around for that), and then running a
mysql2postgresql script against it. I've tried the one in
/contrib/mysql/ and the one on pgsql.com. Both died when they ate all
the memory on the machine (2 gigs worth).

So, any suggestions for someone looking to convert a 3+ gig database?
We're willing to pay for any tool that may work, but I haven't been able
to find any.

Thanks,
Chris

--
Chris Cameron
UpNIX Internet Administrator
ardvark.upnix.net
bitbucket.upnix.net
--
http://www.upnix.com

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org

Browse pgsql-general by date

  From Date Subject
Next Message scott.marlowe 2003-05-16 19:49:46 Re: priority on a process
Previous Message scott.marlowe 2003-05-16 19:28:14 Re: priority on a process