Michael Peppler
Sybase Consulting
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
Sybase on Linux FAQ
Sybperl FAQ
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: Michael Peppler <mpeppler at peppler dot org>
Subject: Re: BCP Error
Date: Sep 8 1999 2:26PM writes:
 > I inherited a bunch of programs that were originally written with Sybperl for Perl 4.  They all
 > do bcps using the bcp API.  I ran them under Perl5 sybperl and all work except one which yields
 > the following error-
 > Usage: Sybase::DBlib::bcp_collen(dbp, varlen, table_column) at /opt/perl5/lib/site_perl/auto/Sybase/Sybperl/ line 18.
 > Any clue what to look for in the program?  I didn't write the stuff
 > and the people who did never ever heard of the KISS principal so the
 > logic is very hard to follow.  I checked out to see what's
 > up with bcp_collen and see that it is called from bcp_colfmt.  The program
 > calls bcp_colfmt, not bcp_collen directly.

bcp_colfmt() should be called with three parameters:

	bcp_colfmt($dbproc, $varlen, $column_number);

My guess is that your code is calling bcp_colfmt() with less than
three parameters, or where one of the params is undefined.

Michael Peppler         -||-  Data Migrations Inc.    -||-
Int. Sybase User Group  -||-
Sybase on Linux mailing list: