selectcol_arrayref failure with DBD::mysql 3.002_4
am 07.12.2005 09:46:22 von Giuseppe MaxiaWith the latest developmend version (3.002_4), selectcol_arrayref
does not work as expected. Instead of returning the first column
of the dataset, it returns undef.
Here is a test case:
#!/usr/bin/perl
use strict;
use warnings;
use DBI;
use Data::Dumper;
my $HOST = 'localhost';
my $dbh = DBI->connect("DBI:mysql:test;host=$HOST"
. ";mysql_read_default_file=$ENV{HOME}/.my.cnf",
undef,undef, {RaiseError => 1})
or die q{can't connect\n};
my $query = qq{show tables from test};
print $DBD::mysql::VERSION, "\n";
print Dumper($dbh->selectcol_arrayref($query));
Running this test with the previous versions, gives correct results:
3.0002
$VAR1 = [
'testaa',
'testad'
];
3.0002_2
$VAR1 = [
'testaa',
'testad'
];
In the latest version, though, it fails:
3.0002_4
$VAR1 = [
undef,
undef
];
Regards,
Giuseppe
--
Giuseppe Maxia
CTO
http://www.StarData.it
MySQL Certified Professional
--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org