Thread: Replicating Binary Data from MS SQL 2000 to PG 8.2

Replicating Binary Data from MS SQL 2000 to PG 8.2

From
"Mike Poe"
Date:
Hello,

I have set up replication between a SQL 2000 server & a PG 8.2.0-1
server (both running on Windows 2003).  To date, I've been replicating
four tables from a database with no problem whatsoever.

I'm attempting to replicate a fifth table, which isn't working so well.

The designer of the SQL 2000 database decided to store binary data
(images) directly in this table.  When I attempt to replicate it to my
PG database, SQL replication agent throws an error:

The process encountered invalid column data in bcp file 'path\to\bcpfile.bcp'.

I assume this has to do with the binary data in the table.

FWIW, I'm able to successfully replicate this table to other SQL 2000 databases.

Is anyone replicating binary data from SQL 2000 to PG, and if so, what
exactly did you do to make it work?  There's next to nothing on the
internet about the error I'm getting... and my feeble attempts so far
have failed to fix the problem.

Thanks!
Mike

Re: Replicating Binary Data from MS SQL 2000 to PG 8.2

From
Richard Huxton
Date:
Mike Poe wrote:
> The designer of the SQL 2000 database decided to store binary data
> (images) directly in this table.  When I attempt to replicate it to my
> PG database, SQL replication agent throws an error:
>
> The process encountered invalid column data in bcp file
> 'path\to\bcpfile.bcp'.
>
> I assume this has to do with the binary data in the table.

Hmm - what are the types involved at the PG end, and how is the data
formatted in the .bcp file?

I'd set up a sixth table with one row and one column and try replicating
that to make it easier to control.

--
   Richard Huxton
   Archonet Ltd