----- Original Message -----
From: "Matt Sergeant" <[EMAIL PROTECTED]>
To: "Jeff Zucker" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, February 21, 2002 12:58
Subject: Re: Should DBI/DBD support empty strings as an alternative to undef
for NULL?


> On 21 Feb 2002, Jeff Zucker wrote:
>
> > Tim Bunce wrote:
> > >
> > > On Wed, Feb 13, 2002 at 01:52:11PM -0800, Jonathan Leffler wrote:
> > > >
> > > > I've been emulating a pseudo-SQL command, UNLOAD, in DBI and
> > > > DBD::Informix, and one of the messy parts is handling the mapping of
> > > > undef into an empty string so as not to get warnings with 'perl -w'.
> >
> > Amen.  The problem is compounded in drivers like DBD::CSV which can't
> > consistently distinguish between empty strings and NULLs.
>
> So don't use CSV. Dump to XML with XML::Generator::DBI :-)

Unfortunately '' == NULL is also a problem in other primitive database
emulators,  Oracle for instance. <G>
--
Mac :})
** I normally forward private questions to the appropriate mail list. **
Ask Smarter: http://www.tuxedo.org/~esr/faqs/smart-questions.html
Give a hobbit a fish and he eats fish for a day.
Give a hobbit a ring and he eats fish for an age.


Reply via email to