OK, guys I am having issues with the DBD::Sybase module. I'm running Strawberry Perl on WinXP, Perl version 5.10.1. I have a program (written by someone else) which requires the DBD::Sybase module. Got that installed (using CPAN), no apparent problems. But when I try to run the program I get the error:
Can't locate DBD/Sybase.pm in @INC (@INC contains: . db /glory/mu/tool
+s/lib C:/strawberry/perl/lib C:/strawberry/perl/site/lib C:\strawberr
+y\perl\vendor\lib .) at dbUpdate.pl line 17.
A quick google search leads me here: What to do when Perl modules aren't in their normal locations. A quick search of my machine finds Sybase.pm in 2 directories: C:\strawberry\cpan\build\DBD-Sybase-1.10-xUBkiW and C:\strawberry\cpan\build\DBD-Sybase-1.10-xUBkiW\blib\lib\DBD. So I add these 3 lines to dbUpdate.pl:
use lib 'C:\strawberry\cpan\build';
use lib 'C:\strawberry\cpan\build\DBD-Sybase-1.10-xUBkiW\blib\lib';
# So Perl can find the DBD::Sybase module
Now I get a different error:
Can't locate loadable object for module DBD::Sybase in @INC (@INC cont
+ains: C:\strawberry\cpan\build\DBD-Sybase-1.10-xUBkiW\blib\lib C:\str
+awberry\cpan\build . db /glory/mu/tools/lib C:/strawberry/perl/lib C:
+/strawberry/perl/site/lib C:\strawberry\perl\vendor\lib .) at dbUpdat
+e.pl line 20.
I really don't know what, exactly, it wants, or where to go from here. Help, please?
Here's the actual code: (or rather, the start of it)
#!/gendat2/proj/bin/perl
#{insert 10 lines of comments here}
use strict; # Restrict unsafe constructs.
use lib 'C:\strawberry\cpan\build';
use lib 'C:\strawberry\cpan\build\DBD-Sybase-1.10-xUBkiW\blib\lib';
# So Perl can find the DBD::Sybase module
use Getopt::Long; # Command line option parser.
use oasisLib; # Common functions.
use DBI; # Database interface.
use DBD::Sybase; # Sybase-specific module.
use Data::Dumper; # Dumps perl data structures.
use FileHandle; # File I/O support.
use Symbol; # Support for using variables as variable names. U
+ber cool.
use Data::Compare; # Compares perl data structures.
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.