Skip Menu |
 

This queue is for tickets about the DBD-ODBC CPAN distribution.

Report information
The Basics
Id: 20917
Status: resolved
Priority: 0/
Queue: DBD-ODBC

People
Owner: Nobody in particular
Requestors: D-Beaudet [...] NGA.GOV
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



X-Scanned-BY: AMaViS-ng at bestpractical
X-Originalarrivaltime: 09 Aug 2006 18:03:39.0920 (UTC) FILETIME=[24AEB100:01C6BBDE]
MIME-Version: 1.0
X-Spam-Status: No, hits=-2.6 required=8.0 tests=BAYES_00,HTML_MESSAGE,UNPARSEABLE_RELAY
Content-Class: urn:content-classes:message
Received-SPF: pass (x1.develooper.com: local policy)
X-Virus-Checked: Checked
Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C6BBDE.24A43FA9"
X-MS-Tnef-Correlator:
Received: from localhost (diesel.bestpractical.com [127.0.0.1]) by diesel.bestpractical.com (Postfix) with ESMTP id B44AB4D8276 for <cpan-bug+dbd-odbc [...] diesel.bestpractical.com>; Wed, 9 Aug 2006 14:03:52 -0400 (EDT)
Received: from la.mx.develooper.com (ss1.fabel.dk [63.251.223.179]) by diesel.bestpractical.com (Postfix) with SMTP id 4C3C04D8275 for <bug-DBD-ODBC [...] rt.cpan.org>; Wed, 9 Aug 2006 14:03:52 -0400 (EDT)
Received: (qmail 15638 invoked by alias); 9 Aug 2006 18:03:51 -0000
Received: from tenable.nga.gov (HELO newfw.nga.gov) (199.16.64.3) by la.mx.develooper.com (qpsmtpd/0.28) with SMTP; Wed, 09 Aug 2006 11:03:48 -0700
Received: from ([172.20.60.36]) by newfw.nga.gov; Wed, 09 Aug 2006 14:02:19 -0400 (EDT)
Received: from sv-e2kb-tdp.NGA.GOV ([172.20.60.65]) by nga-owa.NGA.GOV with Microsoft SMTPSVC(5.0.2195.6713); Wed, 9 Aug 2006 14:03:39 -0400
Delivered-To: cpan-bug+dbd-odbc [...] diesel.bestpractical.com
Subject: CLOB Query returns undef when CLOB text value is empty string
Return-Path: <D-Beaudet [...] NGA.GOV>
Thread-Index: Aca73iS5i7XjULIZTAihpO992TQotg==
X-Original-To: cpan-bug+dbd-odbc [...] diesel.bestpractical.com
X-Spam-Check-BY: la.mx.develooper.com
Date: Wed, 9 Aug 2006 14:03:39 -0400
X-MS-Has-Attach:
Thread-Topic: CLOB Query returns undef when CLOB text value is empty string
Message-Id: <D9576F6F90F1BB4FA35FD9B4EAA30DE601523E [...] sv-e2kb-tdp.nga.gov>
X-Mimeole: Produced By Microsoft Exchange V6.0.6603.0
To: <bug-DBD-ODBC [...] rt.cpan.org>
From: "Beaudet, David P." <D-Beaudet [...] NGA.GOV>
Content-Length: 0
content-type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: us-ascii
Content-Length: 654
Download (untitled) / with headers
text/plain 654b
[ select myclob from mytable where othercolumn = 12345 ] where the myclob value is empty string ('') rather than NULL results in an undefined value being returned for the column instead of the empty string, effectively making it indistinguishable from cases where myclob is NULL. I'm using UnixODBC on Fedora Core 5 with SQL Server 2000 backend. ------------------------------------------------------------------------ ----------- Dave Beaudet d-beaudet@nga.gov (202) 312-2755 ------------------------------------------------------------------------ ----------- "There is no way to peace. Peace is the way."
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: us-ascii
Content-Length: 3923
MIME-Version: 1.0
In-Reply-To: <D9576F6F90F1BB4FA35FD9B4EAA30DE601523E [...] sv-e2kb-tdp.nga.gov>
X-Mailer: MIME-tools 5.418 (Entity 5.418)
Content-Disposition: inline
Message-Id: <rt-3.6.HEAD-9452-1184766493-983.20917-0-0 [...] rt.cpan.org>
References: <D9576F6F90F1BB4FA35FD9B4EAA30DE601523E [...] sv-e2kb-tdp.nga.gov>
Content-Type: text/plain; charset="utf8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Original-Encoding: utf-8
Content-Length: 461
Download (untitled) / with headers
text/plain 461b
Seems to work for me: create table lob (clob1 varchar(max), blob1 varbinary(max)); insert into lob values ('', NULL); perl -e 'use Data::Dumper;use DBI DBI->connect("dbi:ODBC:sqls","xx","yyy");$s = $h->selectall_arrayref("select * from lob");print Dumper($s);' $VAR1 = [ [ '', undef ] ]; with DBD::ODBC 1.14 and DBI 1.58. Perhaps you could be more specific, tell me versions, show schema and provide code.
X-Originalarrivaltime: 18 Jul 2007 14:49:13.0570 (UTC) FILETIME=[CEAF3420:01C7C94A]
MIME-Version: 1.0
X-Spam-Status: No, hits=-2.6 required=8.0 tests=BAYES_00,DKIM_POLICY_SIGNSOME,DK_POLICY_SIGNSOME,SPF_PASS
Content-Class: urn:content-classes:message
Received-SPF: pass (x1.develooper.com: local policy)
References: <RT-Ticket-20917 [...] rt.cpan.org> <D9576F6F90F1BB4FA35FD9B4EAA30DE601523E [...] sv-e2kb-tdp.nga.gov> <rt-3.6.HEAD-9452-1184766493-983.20917-6-0 [...] rt.cpan.org>
X-Virus-Checked: Checked
Content-Type: multipart/mixed; boundary="----_=_NextPart_001_01C7C94A.CE76256C"
X-MS-Tnef-Correlator: <E52EF6AB8656CD4DA8AA712FC2BE09F8553FE2 [...] SV-MAIL-TDP.NGA.GOV>
Received: from la.mx.develooper.com (x1.develooper.com [63.251.223.170]) by diesel.bestpractical.com (Postfix) with SMTP id A3CDB4D80FB for <bug-DBD-ODBC [...] rt.cpan.org>; Wed, 18 Jul 2007 10:49:27 -0400 (EDT)
Received: (qmail 15491 invoked by alias); 18 Jul 2007 14:49:27 -0000
Received: from tenable.nga.gov (HELO newfw.nga.gov) (199.16.64.3) by la.mx.develooper.com (qpsmtpd/0.28) with SMTP; Wed, 18 Jul 2007 07:49:24 -0700
Received: from mail.NGA.GOV ([172.20.60.92]) by mail.NGA.GOV with Microsoft SMTPSVC(5.0.2195.6713); Wed, 18 Jul 2007 10:49:13 -0400
Delivered-To: cpan-bug+dbd-odbc [...] diesel.bestpractical.com
Subject: RE: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text value is empty string
Return-Path: <D-Beaudet [...] NGA.GOV>
X-Spam-Check-BY: la.mx.develooper.com
X-Original-To: bug-DBD-ODBC [...] rt.cpan.org
Thread-Index: AcfJQlL+zgH3nlUWSvqT1Z7OC7+J+gACG7Ce
Date: Wed, 18 Jul 2007 10:48:51 -0400
Thread-Topic: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text value is empty string
X-MS-Has-Attach:
Message-Id: <E52EF6AB8656CD4DA8AA712FC2BE09F8553FE2 [...] SV-MAIL-TDP.NGA.GOV>
X-Mimeole: Produced By Microsoft Exchange V6.5
To: <bug-DBD-ODBC [...] rt.cpan.org>
From: "Beaudet, David P." <D-Beaudet [...] NGA.GOV>
RT-Message-ID: <rt-3.6.HEAD-9432-1184770174-643.20917-0-0 [...] rt.cpan.org>
Content-Length: 0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
X-RT-Original-Encoding: iso-8859-1
X-RT-Original-Encoding: utf-8
Content-Length: 801
Download (untitled) / with headers
text/plain 801b
I'll try to dig up more info today on this. Show quoted text
-----Original Message----- From: Martin J Evans via RT [mailto:bug-DBD-ODBC@rt.cpan.org] Sent: Wed 7/18/2007 9:48 AM To: Beaudet, David P. Subject: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text value is empty string <URL: http://rt.cpan.org/Ticket/Display.html?id=20917 > Seems to work for me: create table lob (clob1 varchar(max), blob1 varbinary(max)); insert into lob values ('', NULL); perl -e 'use Data::Dumper;use DBI DBI->connect("dbi:ODBC:sqls","xx","yyy");$s = $h->selectall_arrayref("select * from lob");print Dumper($s);' $VAR1 = [ [ '', undef ] ]; with DBD::ODBC 1.14 and DBI 1.58. Perhaps you could be more specific, tell me versions, show schema and provide code.
content-type: application/ms-tnef; name="winmail.dat"
Content-Transfer-Encoding: base64
Content-Length: 3328
Download winmail.dat
application/ms-tnef 3.2k

Message body not shown because it is not plain text.

MIME-Version: 1.0
In-Reply-To: <rt-3.6.HEAD-9432-1184770174-643.20917-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
References: <RT-Ticket-20917 [...] rt.cpan.org> <D9576F6F90F1BB4FA35FD9B4EAA30DE601523E [...] sv-e2kb-tdp.nga.gov> <rt-3.6.HEAD-9452-1184766493-983.20917-6-0 [...] rt.cpan.org> <E52EF6AB8656CD4DA8AA712FC2BE09F8553FE2 [...] SV-MAIL-TDP.NGA.GOV> <rt-3.6.HEAD-9432-1184770174-643.20917-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-26547-1271269233-377.20917-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 1095
As I've nothing on this in over 6 months I am going to close this rt. If you have a problem with that let me know and I'll reopen it. Martin -- Martin J. Evans Wetherby, UK On Wed Jul 18 10:49:34 2007, D-Beaudet@NGA.GOV wrote: Show quoted text
> > I'll try to dig up more info today on this. > > -----Original Message----- > From: Martin J Evans via RT [mailto:bug-DBD-ODBC@rt.cpan.org] > Sent: Wed 7/18/2007 9:48 AM > To: Beaudet, David P. > Subject: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text > value is empty string > > > <URL: http://rt.cpan.org/Ticket/Display.html?id=20917 > > > Seems to work for me: > > create table lob (clob1 varchar(max), blob1 varbinary(max)); > insert into lob values ('', NULL); > > perl -e 'use Data::Dumper;use DBI > DBI->connect("dbi:ODBC:sqls","xx","yyy");$s = > $h->selectall_arrayref("select * from lob");print Dumper($s);' > $VAR1 = [ > [ > '', > undef > ] > ]; > > with DBD::ODBC 1.14 and DBI 1.58. > > Perhaps you could be more specific, tell me versions, show schema and > provide code. >
From D-Beaudet [...] NGA.GOV Wed Apr 14 14: 28:20 2010
X-Originalarrivaltime: 14 Apr 2010 18:28:11.0922 (UTC) FILETIME=[3D405F20:01CADC00]
MIME-Version: 1.0
X-Spam-Status: No, score=-10.599 tagged_above=-99.9 required=10 tests=[BAYES_00=-2.599, RCVD_IN_DNSWL_HI=-8] autolearn=ham
In-Reply-To: <rt-3.8.HEAD-26547-1271269233-1708.20917-6-0 [...] rt.cpan.org>
Content-Class: urn:content-classes:message
X-Spam-Flag: NO
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
Content-Type: text/plain; charset="utf-8"
Message-ID: <E52EF6AB8656CD4DA8AA712FC2BE09F803381447 [...] SV-MAIL-TDP.NGA.GOV>
X-MS-Tnef-Correlator:
X-RT-Original-Encoding: utf-8
X-Spam-Score: -10.599
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 70576240640 for <cpan-bug+DBD-ODBC [...] hipster.bestpractical.com>; Wed, 14 Apr 2010 14:28:19 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id pV1GR9zDQmGU for <cpan-bug+DBD-ODBC [...] hipster.bestpractical.com>; Wed, 14 Apr 2010 14:28:11 -0400 (EDT)
Received: from la.mx.develooper.com (x1.develooper.com [207.171.7.70]) by hipster.bestpractical.com (Postfix) with SMTP id 280D324063E for <bug-DBD-ODBC [...] rt.cpan.org>; Wed, 14 Apr 2010 14:28:10 -0400 (EDT)
Received: (qmail 22606 invoked by uid 103); 14 Apr 2010 18:28:18 -0000
Received: from x16.dev (10.0.100.26) by x1.dev with QMQP; 14 Apr 2010 18:28:18 -0000
Received: from mail.nga.gov (HELO mail.NGA.GOV) (199.16.64.22) by 16.mx.develooper.com (qpsmtpd/0.80) with ESMTP; Wed, 14 Apr 2010 11:28:14 -0700
Received: from mail.NGA.GOV ([172.20.60.92]) by mail.NGA.GOV with Microsoft SMTPSVC(5.0.2195.6713); Wed, 14 Apr 2010 14:28:11 -0400
Delivered-To: cpan-bug+DBD-ODBC [...] hipster.bestpractical.com
Subject: RE: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text value is empty string
Return-Path: <D-Beaudet [...] NGA.GOV>
X-Spam-Check-BY: 16.mx.develooper.com
X-Original-To: cpan-bug+DBD-ODBC [...] hipster.bestpractical.com
X-RT-Mail-Extension: dbd-odbc
Thread-Index: Acrb/yzhOgBYjn5mQFOkE9TuI/+KWwAAQhow
Date: Wed, 14 Apr 2010 14:28:11 -0400
X-Spam-Level:
X-MS-Has-Attach:
Thread-Topic: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text value is empty string
X-Mimeole: Produced By Microsoft Exchange V6.5
To: <bug-DBD-ODBC [...] rt.cpan.org>
Content-Transfer-Encoding: quoted-printable
From: "Beaudet, David" <D-Beaudet [...] NGA.GOV>
RT-Message-ID: <rt-3.8.HEAD-26545-1271269709-608.20917-0-0 [...] rt.cpan.org>
Content-Length: 1567
Download (untitled) / with headers
text/plain 1.5k
That's fine, I've not had the time to research further and found a workaround. Show quoted text
> -----Original Message----- > From: Martin J Evans via RT [mailto:bug-DBD-ODBC@rt.cpan.org] > Sent: Wednesday, April 14, 2010 2:21 PM > To: Beaudet, David > Subject: [rt.cpan.org #20917] CLOB Query returns undef when CLOB text > value is empty string > > <URL: https://rt.cpan.org/Ticket/Display.html?id=20917 > > > As I've nothing on this in over 6 months I am going to close this rt.
If Show quoted text
> you have a problem with that let me know and I'll reopen it. > > Martin > -- > Martin J. Evans > Wetherby, UK > > On Wed Jul 18 10:49:34 2007, D-Beaudet@NGA.GOV wrote:
> > > > I'll try to dig up more info today on this. > > > > -----Original Message----- > > From: Martin J Evans via RT [mailto:bug-DBD-ODBC@rt.cpan.org] > > Sent: Wed 7/18/2007 9:48 AM > > To: Beaudet, David P. > > Subject: [rt.cpan.org #20917] CLOB Query returns undef when CLOB
text Show quoted text
> > value is empty string > > > > > > <URL: http://rt.cpan.org/Ticket/Display.html?id=20917 > > > > > Seems to work for me: > > > > create table lob (clob1 varchar(max), blob1 varbinary(max)); > > insert into lob values ('', NULL); > > > > perl -e 'use Data::Dumper;use DBI > > DBI->connect("dbi:ODBC:sqls","xx","yyy");$s = > > $h->selectall_arrayref("select * from lob");print Dumper($s);' > > $VAR1 = [ > > [ > > '', > > undef > > ] > > ]; > > > > with DBD::ODBC 1.14 and DBI 1.58. > > > > Perhaps you could be more specific, tell me versions, show schema
and Show quoted text
> > provide code. > >


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.