By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,852 Members | 1,426 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,852 IT Pros & Developers. It's quick & easy.

how to install DBD:ODBC on Windows XP

P: 4
I just installed ActivePerl-5.8.8.822 & downloaded DBD-ODBC. Did this on Windows XP:

ppm install DBD-ODBC.ppd

got this:

ppm install failed: Can't find any package that provide DBI version 1.21 for DB-ODBC

~~~

I'm a perl newbie. I'll be glad if someone could help on this. I am now trying to use Perl to migrate some data.

Regards,

Arlie
Apr 1 '08 #1
Share this Question
Share on Google+
5 Replies


nithinpes
Expert 100+
P: 410
I just installed ActivePerl-5.8.8.822 & downloaded DBD-ODBC. Did this on Windows XP:

ppm install DBD-ODBC.ppd

got this:

ppm install failed: Can't find any package that provide DBI version 1.21 for DB-ODBC

~~~

I'm a perl newbie. I'll be glad if someone could help on this. I am now trying to use Perl to migrate some data.

Regards,

Arlie
I am not sure about exact implication of the error :( .
The package DBD::ODBC is dependent on DBI. But once you type,
Expand|Select|Wrap|Line Numbers
  1. ppm install DBD-odbc
  2.  
all the dependencies should be automatically downloaded. May be you have DBI installed which is older than version 1.21. You may try to re-install DBI and install DBD::ODBC.
Expand|Select|Wrap|Line Numbers
  1. ppm uninstall DBI
  2. ppm install DBI
  3. ppm install DBD-odbc
  4.  
  5.  
Apr 1 '08 #2

P: 4
I am not sure about exact implication of the error :( .
The package DBD::ODBC is dependent on DBI. But once you type,
Expand|Select|Wrap|Line Numbers
  1. ppm install DBD-odbc
  2.  
all the dependencies should be automatically downloaded. May be you have DBI installed which is older than version 1.21. You may try to re-install DBI and install DBD::ODBC.
Expand|Select|Wrap|Line Numbers
  1. ppm uninstall DBI
  2. ppm install DBI
  3. ppm install DBD-odbc
  4.  
  5.  
Thanks for your reply. I finally was able to install it. I simply tried installing all available packages and finally was able to install it using DBD-ODBC-1.11. I still need to test it though if it really works.

I got the it from here: http://ppm4.activestate.com/PPMPackages/zips
Apr 3 '08 #3

P: 4
I am not sure about exact implication of the error :( .
The package DBD::ODBC is dependent on DBI. But once you type,
Expand|Select|Wrap|Line Numbers
  1. ppm install DBD-odbc
  2.  
all the dependencies should be automatically downloaded. May be you have DBI installed which is older than version 1.21. You may try to re-install DBI and install DBD::ODBC.
Expand|Select|Wrap|Line Numbers
  1. ppm uninstall DBI
  2. ppm install DBI
  3. ppm install DBD-odbc
  4.  
  5.  
I downloaded the ppd files from the office and install it at home. Since I don't have internet at home. I might be missing some dependcies because as much as dbd-odbc installed I still can't use it. I got this error:

DBD::ODBC initialisation failed: Can't locate object method "driver" via package
"DBD::ODBC" at C:/Perl/lib/DBI.pm line 782.

Perhaps the capitalisation of DBD 'ODBC' isn't right. at odbc.test.pl line 6
Apr 4 '08 #4

P: 4
I downloaded the ppd files from the office and install it at home. Since I don't have internet at home. I might be missing some dependcies because as much as dbd-odbc installed I still can't use it. I got this error:

DBD::ODBC initialisation failed: Can't locate object method "driver" via package
"DBD::ODBC" at C:/Perl/lib/DBI.pm line 782.

Perhaps the capitalisation of DBD 'ODBC' isn't right. at odbc.test.pl line 6
Below is my odbc test code:

Expand|Select|Wrap|Line Numbers
  1. use strict;
  2. use DBI;
  3.  
  4. use DBD::ODBC;
  5. print $DBD::ODBC::VERSION;
  6. my $dbh = DBI-> connect('dbi:ODBC:Luke');
Apr 4 '08 #5

eWish
Expert 100+
P: 971
Try changing the last line to this. Also, check out the DBD::ODBC docs for more information.

Expand|Select|Wrap|Line Numbers
  1. my $dbh = DBI->connect('dbi:ODBC:DSN', 'user', 'password');
--Kevin
Apr 4 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.