Re: Porting SQL Server 2000 database to PostgreSQL

From: Richard Huxton <dev(at)archonet(dot)com>
To: Rod Early <REarly(at)jswcoinc(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Porting SQL Server 2000 database to PostgreSQL
Date: 2004-05-21 08:36:03
Message-ID: 40ADBF73.40809@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Rod Early wrote:
> I have the task of converting a SQL Server 2000 database to
> PostgreSQL. The data itself does not need to be converted, but the
> structure and stored procedures must be.
>
> I expect that converting tables and views will be simple. I expect
> that converting stored procedures and user-defined functions from
> T-SQL to PostgreSQL will be more complex.

There are a couple of notes on the techdocs site detailing conversion
from MS-SQL.
http://techdocs.postgresql.org/
Where you'll need to put some extra work in:
- Returning multiple recordsets from a function/stored-proc (we don't)
- In/out parameters (pass by ref) - we don't
- Exception handling (needs improvement)
You have some useful new tools available:
- Partial/conditional/functional indexes
- Lots of different procedural languages available
- a bunch of stuff that has slipped my mind momentarily
Oh, PG returns the complete result set in one go, so if you want to see
the first row of 100,000 quickly use an explicit cursor.

> In any case, I am looking for recommendations and counsel regarding my
> expectations. I have much Windows 2000/NT and SQL Server experience,
> and some Unix/Linux experience, probably post-beginner level. (I used
> to work with Unix and VMS all the time in college 15 years ago but
> haven't touched it since.)

The standard guide to the config file and performance tuning is at
"GeneralBits":
http://www.varlena.com/varlena/GeneralBits/Tidbits/index.php

> I plan to use a Windows client such as pgAdminIII to administer and
> work with the database in PostgreSQL. The database is used by a
> WindowsCE application, so I will need to change its data access layer
> from SQLClient to whatever is needed in CE and Windows to access
> PostgreSQL.

Looks like you've found the .net/odbc libraries in your next post. Can't
say anything about CE as an environment.

--
Richard Huxton
Archonet Ltd

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Richard Huxton 2004-05-21 10:38:26 Re: Web DB Management tool
Previous Message Tom Lane 2004-05-21 07:07:15 Re: can't get async mode to deliver small batches of rows