Skip to Content.
Sympa Menu

freetds - Re: [freetds] named pipe as a host file for freebcp

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Constantin Vasilyev <vasilyev AT ncbi.nlm.nih.gov>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] named pipe as a host file for freebcp
  • Date: Wed, 03 Jan 2007 10:46:53 -0500

It seems like datacopy utility doesn't copy image fields well.

Here's my setup:

use testdb
go
create table Blob1(id int primary key, data image null)
create table Blob2(id int primary key, data image null)
insert Blob1 select 1, 0x1234567890abcdef
go

I tried to copy the data (single row) from Blob1 into Blob2.
datacopy utility built as part of 0.64 stable didn't work at all:

.../datacopy -SMSSQL0/anyone/allowed/testdb/Blob1 -DMSSQL0/anyone/allowed/testdb/Blob2 -t
Error in dbnumcols
datacopy: table structures do not match. terminating


And one built out of latest CVS source worked with no errors but didn't copy image data:

> ./datacopy -SMSSQL0/anyone/allowed/testdb/Blob1 -DMSSQL0/anyone/allowed/testdb/Blob2 -t
> sqsh-ms -S MSSQL0 -D testdb
[101] MSSQL0.testdb.1> select * from Blob2; -mvert
id: 1
data: NULL

[102] MSSQL0.testdb.1> select * from Blob1; -mvert
id: 1
data: 0x1234567890abcdef

Constantin

Thompson, Bill D (London) wrote:
Hi Constantin,

If you want to copy data in bulk from one server to another, you can try
using the "datacopy" executable we have in freeTDS.
It was designed to do this job.
Bill

-----Original Message-----
From: freetds-bounces AT lists.ibiblio.org
[mailto:freetds-bounces AT lists.ibiblio.org] On Behalf Of Constantin
Vasilyev
Sent: 22 December 2006 15:20
To: freetds AT lists.ibiblio.org
Subject: [freetds] named pipe as a host file for freebcp


Hi,

Native Sybase bcp allows using of named pipe as a host file for "bcp
in".
It is extremely useful for coping large tables from one server to
another
because virtually no disk space is required this way.
I wonder how hard would it be to implement that in freetds bcp?

Thanks,
Constantin Vasilyev
_______________________________________________
FreeTDS mailing list
FreeTDS AT lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/freetds
--------------------------------------------------------

If you are not an intended recipient of this e-mail, please notify the
sender, delete it and do not read, act upon, print, disclose, copy, retain or
redistribute it. Click here for important additional terms relating to this
e-mail. http://www.ml.com/email_terms/
--------------------------------------------------------
_______________________________________________
FreeTDS mailing list
FreeTDS AT lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/freetds





Archive powered by MHonArc 2.6.24.

Top of Page