Skip Menu |
 

This queue is for tickets about the DBI CPAN distribution.

Report information
The Basics
Id: 99508
Status: resolved
Priority: 0/
Queue: DBI

People
Owner: Nobody in particular
Requestors: MITHALDU [...] cpan.org
Cc:
AdminCc:

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



Subject: Tables will erroneously be opened in current folder if f_dir set to a relative path that does not exist
Download (untitled) / with headers
text/plain 1.1k
Ticketing this as per Tux' request. I'll describe it as a series of shell commands. Of these, the first two behaviors are misbehavior and only the last case is correct. In the first case it should not search in '.', but ONLY in 'test', and raise the error accordingly. In the second case it should not search in '.' and use the file 'yy.csv' found there. Instead it should search only in 'test' and disregard files found elsewhere. $ cd /tmp $ perl -MDBI -MDP -wE'$a=DBI->connect("dbi:CSV:f_dir=./test;f_ext=.csv/r",undef,undef,{RaiseError=>1});$b=$a->prepare("select distinct foo from yy");$b->execute;DDumper$b->fetch' ... Cannot open /tmp/yy.csv: No such file or directory (2) at /pro/lib/perl5/site_perl/5.20.0/x86_64-linux-thread-multi-ld/DBI/DBD/SqlEngine.pm line 1589. $ echo [useful content] > yy.csv $ perl -MDBI -MDP -wE'$a=DBI->connect("dbi:CSV:f_dir=./test;f_ext=.csv/r",undef,undef,{RaiseError=>1});$b=$a->prepare("select distinct foo from yy");$b->execute;DDumper$b->fetch' [ 1 ] $ mkdir test $ mv yy.csv test/ $ perl -MDBI -MDP -wE'$a=DBI->connect("dbi:CSV:f_dir=./test;f_ext=.csv/r",undef,undef,{RaiseError=>1});$b=$a->prepare("select distinct foo from yy");$b->execute;DDumper$b->fetch' [ 1 ]
Download (untitled) / with headers
text/plain 294b
Even with an absolute path it misbehaves: $ rm -rf test $ perl -MDBI -MData::Dumper -wE'$a=DBI->connect("dbi:CSV:f_dir=/tmp/test/;f_ext=.csv/r",undef,undef,{RaiseError=>1});$b=$a->prepare("select distinct foo from yy");$b->execute;' ... Cannot open /tmp/yy.csv: No such file or directory (2)


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.