I have data in postgres that I need to programmatically move to sql server on a scheduled basis. The tables have the all have same schema and the tables are not very relational (no foreign keys), but I think I can just use WITH NO CHECK
if there are.
I have ADO.Net connectors for both servers, so I think I can just select from the postgres to a DataTable
and then INSERT INTO
the SQL SERVER tables. However, I'm a little concerned on performance.
My question is how hard would it be to use the Postgres COPY
command to export to say CSV, and then use bcp.exe to import the CSV into SQL SERVER. Does this sound like the way to go? I can see this needing to scale to ~750k records being copied per schedule.