
S_Shrum
User
Sep 26, 2001, 4:59 PM
Post #1 of 2
(859 views)
|
|
DBD::AnyData under FreeBSD - give advice
|
Can't Post
|
|
I am attempting to set up DBI with DBD:AnyData. I am running into a issue in that it is not working. Here is the simple code that I have to test with: <code> #!/usr/bin/perl BEGIN { unshift(@INC, '/a/home/shrum/cgi-bin/lib'); } use DBI; my $dbh = DBI->connect('dbi:AnyData(RaiseError=>1):'); $dbh->func('sites', 'Pipe', 'flying_sites.dat', 'ad_catalog'); my $sth = $dbh->prepare("SELECT State FROM sites"); $sth->execute(); while(my $row = $sth->fetch) { print "@$row\n"; } </code> I am getting the following error in the log file: <code> DBD::AnyData initialisation failed: Can't locate object method "driver" via package "DBD::AnyData" at /usr/local/lib/perl5/site_perl/5.005/i386-freebsd/DBI.pm line 481. Perhaps the capitalisation of DBD 'AnyData' isn't right. at /a/home/shrum/cgi-bin/dbd-installed.pl line 15 [Wed Sep 26 17:34:44 2001] db_table2.pl: Required FILE parameter not specified. </code> I created a simple DBI call to see what drivers were installed to make sure that I at least had AnyData listed: http://www.shrum.net/cgi-bin/dbd-installed.pl The returned result lists ADO and AnyData. Any ideas on what I am doing wrong? Sean Shrum sean@shrum.net www.shrum.net
|