The problem seems more like your DBI module is not in right path. You
need to tell @INC variable where to look for the DBI module.
You have to write a begin block something like
BEGIN {
Unshift(@INC, "< full path to dbi module>");
}
HTH
Cvr/
Venkata Reddy
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: Friday, April 01, 2005 1:35 AM
To: perl-unix-users@listserv.ActiveState.com
Subject: Perl-Unix-Users Digest, Vol 14, Issue 10
Send Perl-Unix-Users mailing list submissions to
perl-unix-users@listserv.ActiveState.com
To subscribe or unsubscribe via the World Wide Web, visit
http://listserv.ActiveState.com/mailman/listinfo/perl-unix-users
or, via email, send a message with subject or body 'help' to
[EMAIL PROTECTED]
You can reach the person managing the list at
[EMAIL PROTECTED]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Perl-Unix-Users digest..."
Today's Topics:
1. Db-Access Problem (Avadhani, Subramanya)
2. Re: Db-Access Problem (michael higgins)
--
Message: 1
Date: Thu, 31 Mar 2005 15:52:13 +0530
From: "Avadhani, Subramanya" <[EMAIL PROTECTED]>
Subject: [Perl-unix-users] Db-Access Problem
To:
Message-ID:
<[EMAIL PROTECTED]
et>
Content-Type: text/plain; charset="us-ascii"
Hi List,
I am not sure if this list would help me out if I am a windows
Perl user.I am trying to write a small perl script to delete some
records from a DB(MS Access) using the DBI module. As DBI is not part of
standard distribution of Perl, I had to get it and install it for
Windows. After configuring the DSN I wrote the below simple code,
use DBI;
$db = DBI->connect("dbi:ODBC:Passdb") or die("$! ");
print "enter server name\n";
chomp($id = );
$sql = $db->do("delete from pass_tb where Server_Name = $id");
$db->disconnect;
Now I get the error
Can't locate loadable object for module DBI in @INC (@INC contains:
c:/perl/lib
c:/perl/site/lib .) at c:/perl/lib/DBI.pm line 254
BEGIN failed--compilation aborted at c:/perl/lib/DBI.pm line 254.
Compilation failed in require at delete.pl line 1.
BEGIN failed--compilation aborted at delete.pl line 1.
I am not sure how to get the DBI module for windows or if it is possible
try to make changes to DBI itself.
Any Help is greatly appreciated .
Thanks,
Subbu
--
Message: 2
Date: Thu, 31 Mar 2005 09:26:41 -0500
From: michael higgins <[EMAIL PROTECTED]>
Subject: Re: [Perl-unix-users] Db-Access Problem
To: perl-unix-users@listserv.ActiveState.com
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=US-ASCII
On Thu, 31 Mar 2005 15:52:13 +0530
"Avadhani, Subramanya" <[EMAIL PROTECTED]> wrote:
> Hi List,
>I am not sure if this list would help me out if I am a windows
> Perl user.I am trying to write a small perl script to delete some
> records from a DB(MS Access) using the DBI module. As DBI is not part
of
> standard distribution of Perl, I had to get it and install it for
> Windows. After configuring the DSN I wrote the below simple code,
>
[snip]
>
> Can't locate loadable object for module DBI in @INC (@INC contains:
> c:/perl/lib
> c:/perl/site/lib .) at c:/perl/lib/DBI.pm line 254
> BEGIN failed--compilation aborted at c:/perl/lib/DBI.pm line 254.
> Compilation failed in require at delete.pl line 1.
> BEGIN failed--compilation aborted at delete.pl line 1.
>
> I am not sure how to get the DBI module for windows or if it is
possible
> try to make changes to DBI itself.
Sounds like you didn't install it properly. Unless you built your own
perl, you often need to get a pre-compiled module... usually via ppm.
Just type 'ppm' at a 'command prompt'.
FWIW, I've used the ODBC module for lots of DB wrecking at work. '-)
HTH.
--
|\ /| | | ~ ~
| \/ | |---| `|` ?
||ichael | |iggins\^ /
michael[dot]higgins[at]snet[dot]net
--
___
Perl-Unix-Users mailing list
Perl-Unix-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
End of Perl-Unix-Users Digest, Vol 14, Issue 10
***
___
Perl-Unix-Users mailing list
Perl-Unix-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs