|
|
sybperl-l Archive
Up Prev Next
From: deolinda dot pereira at sybase dot pt
Subject: BCP with Sybperl
Date: Aug 8 2002 4:11PM
Hi,
I'm trying to write a BCP routine (export data from a .txt file to import to a
table) with Sybperl but i get an error:
"Error converting client characters into server's character set. Some
character(s) could not be converted."
I followed the example that comes with sybperl (file bcp.pl). This error
appears sometimes, the BCP ends, but it didn't copy all the lines. Why this is
happening? It has to do something with the character set? If it does how do i
solve this?
Then i tryed to write de next code:
use Sybase::BCP;
require 'sybutil.pl';
$bcp = new Sybase::BCP $login, $pass, $server;
$bcp->config(INPUT => $file,
OUTPUT => $table
FIELDS => 33,
SEPARATOR => ';');
$bcp->run;
But this time i get a different error:
"Attempt to convert data stopped by syntax error in source field."
Once more, i don't know i to solve this...?
Thanks,
Deolinda
|