David
David

Reputation: 1071

Good way to copy data from SQL Server to Posgres

I am using OPENQUERY through an ODBC connection to insert records from SQL server to Postgres. But it's very slow - a few minutes for 10000 records.
Also, SQL Server Service crashes when amount of data gets too large.

Anybody knows a better way ?

Upvotes: 0

Views: 2744

Answers (2)

Ehsan Mirsaeedi
Ehsan Mirsaeedi

Reputation: 7592

The standard and the simplest way is to use SSIS built-in Import/Export feature. You can find the steps in another SO question/answer.

Upvotes: 0

Bohemian
Bohemian

Reputation: 425358

Export the data in CSV format using a db utility command.

Import the data using the postgres COPY command.

Upvotes: 2

Related Questions