Re: Can't locate DBI.pm in @INC
by Ovid (Cardinal) on Dec 10, 2001 at 21:46 UTC
|
If you have just installed ActiveState, you don't have DBI as this is not a standard module. Use ppm. At the command line, type 'ppm'. When the prompt comes up, type 'install DBI' and follow the prompts.
| [reply] |
Re: Can't locate DBI.pm in @INC
by Anonymous Monk on Apr 16, 2004 at 08:51 UTC
|
If you don't have active perl (and hence don't have ppm), you can also get DBI like this:
perl -MCPAN -e 'install DBI'
That fixed it for me. And then you might need to install drivers like this (for Postgres):
perl -MCPAN -e 'install DBD::Pg'
Hope that helps.
| [reply] [d/l] [select] |
Can't locate DBI.pm in @INC
by Avitar (Acolyte) on Nov 24, 2004 at 19:15 UTC
|
Perl is installed, but the eggheads in their infinate wisdom forgot to add the path variable for the lib's you need for your os.
I was able to work around this by adding "C:\Perl\lib;C:\Perl\site\lib"
to the 'PATH' and/or 'PERL5LIB' environment variable.
In windows 2000/2003/xp it cen be found near: right click my computer->properties->avanced tab Environmental Var
David Smith
Avitar.Net | [reply] |
Re: Can't locate DBI.pm in @INC
by Khen1950fx (Canon) on Jul 21, 2006 at 23:17 UTC
|
Granted---this an old question, but I thought I would revisit it to see if I could help my friends. When I first started in Perl, I got the "Can't locate" warning a lot. In fact, most of the time. Then I discovered what it was that I was doing wrong. OK...I was a newbie...In my case, the answer was simple. I created a folder on my Desktop and named it, say Algorithm::Diff. Then I would put the tarball in it and extract it there. Then I would run perl Makefile.PL, then make---oops! "Can't locate" would pop up and up. Hmmm...I admit that it took me a long time to figure out this one---Perl accepts a double colon, but my system was looking for a single dash. The Algorithm::Diff folder on my Desktop was the problem. I renamed it to Algorithm-Diff, and then it worked. I learned my lesson---keep it simple. A simple mistake is usually the most deadly...
If the path's ok, then the next thing I look at is dependencies. The output will usually tell you what module is missing. Sometimes the program will ask you if you want the module installed. Sometimes not. If not, then install it manually. Then I use pmvers from pmtools to make sure that the dependency is actually there. If it isn't, then pmvers will come back at you with it's own "Can't locate...". Check all the dependencies and the module that you're installing.
Based on my own experience, the procedures above have solved my "Can't locate" problem 90% of the time. The remaining 10%---that's another question. | [reply] |
|
there may be multiple perl binaries installed on your machine check your PATH which one are you accessing. I went thru this frustration once.
| [reply] |
|
Hi,
On my case, my program works simetimes fine but simetimes i got the error "can't locate", all dependecies are installed. it's hard to find the source of this problem.
| [reply] |
Re: Can't locate DBI.pm in @INC
by Anonymous Monk on Jun 18, 2004 at 03:16 UTC
|
i have this problem..:
CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are:
Can't locate http://www.etude.com.mx/cgi-bin/cgi-lib.pl in @INC (@INC contains: C:/Perl/lib C:/Perl/site/lib .) at \\172.21.6.14\s002\etude.com.mx\CGI-BIN\envia.pl line 6.
mi mail is: tizac2001@etude.com.mx
I dont find the answer of this error
| [reply] |
Re: Can't locate DBI.pm in @INC
by Anonymous Monk on Feb 07, 2003 at 05:07 UTC
|
| [reply] |
Re: Can't locate DBI.pm in @INC
by Anonymous Monk on Mar 06, 2010 at 22:01 UTC
|
bash-2.05$ ./abc.pl
Can't locate DBI.pm in @INC (@INC contains:
/usr/perl5/5.6.1/lib/sun4-solaris-64int /usr/perl5/5.6.1/lib /usr/perl5/site_perl/5.6.1/sun4-solaris-64int /usr/perl5/site_perl/5.6.1 /usr/perl5/site_perl /usr/perl5/vendor_perl/5.6.1/sun4-solaris-64int /usr/perl5/vendor_perl/5.6.1 /usr/perl5/vendor_perl .) at ./abc.pl line 4.
BEGIN failed--compilation aborted at ./abc.pl line 4. | [reply] |
|
| [reply] |
Re: Can't locate DBI.pm in @INC
by krishjack (Initiate) on Dec 11, 2001 at 05:01 UTC
|
| [reply] |
Re: Can't locate DBI.pm in @INC
by Anonymous Monk on Oct 23, 2003 at 00:37 UTC
|
| [reply] |