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: A patch proposal to the NULL-value problem on blk_rowxfer
Date: Jun 24 2002 10:24PM

On Sat, 2002-06-22 at 07:03, Masatsuyo Takahashi wrote:
> Scott Zetlan writes:
> > So the issue isn't whether you get defined vs. undefined values --
> although
> > undef will always produce NULL --  in fact, the code goes something like
> > this:
> >
> > my $null_pattern = $self->{_blk_global}->{'NULL'} || '^$';
> > # Skip a bit, brother...
> > if (defined ($null_pattern) && $data[$i] =~ /$null_pattern/o) {
> >     $data[$i] = undef;
> > }
> This, when the $null_pattern is '^$', is what I first expected from the
> patch.
> Depending on the situation, the values people want to be NULLs are not
> retricted to undef or "" alone, and it is the job of Sybase::BLK, not that
> of
> blk_rowxfer, to care for those various needs.

Exactly. Because someone may have a different need when using
blk_rowxfer() directly, and we shouldn't make it impossible (or very
difficult) to do things differently)

After all, the Sybase::CTlib module is just a very thin API layer -
hence the Sybase::BLK and Sybase::Simple modules.

Michael Peppler / / / ZetaTools, Inc /
ZetaTools: Call perl functions as Sybase stored procedures!