FAQ
Hi,



I have been stuck with this error since long now, and have tried almost
everything available on web but no luckL

Any help would be greatly appreciated.



When I try to execute a PERL scripts I am getting an error:



ORACLE_HOME=/u01/app/oracle/product/10.2.0

TNS_ADMIN=/usr/local/tns

Can't locate object method "connect" via package "DBI" at
/opt/mabl/agg/dgt/batch-proc/contentdownload/PROD-BBY/bin/DeltaFlag.pm
line 67.



Before getting this error, I was getting an error where the script was
not able to locate the DBI.pm module, hence I pointed my script to use
the below path to locate DBI.pm:



/u01/app/oracle/product/10.2.0/perl/lib/site_perl/5.8.3/Apache



We are migrating from HPUX system to Linux, hence the scripts which we
have been using since long are not working as is and they require some
changes.



Pls help!



Thanks!



Khushboo Chokhani

Wipro Technologies
Mobile : +1 (612)-354-1243

Search Discussions

  • John Scoles at Sep 13, 2011 at 11:07 am
    You will most likely have to reinstall DBD::Oracle and the Oracle client one your new target linux box

    try

    Perl -MDBD::Oracle -e 'print DBD::Oracle::VERSION'

    To see if it is installed on your new box.

    If not you will have to get it from CPAN as well as an Oracle Client

    I would use the instant client which you can get here

    http://www.oracle.com/technetwork/database/features/instant-client/index-097480.html CheersJohn
    Subject: Need help with DBI connect
    Date: Mon, 12 Sep 2011 10:18:05 -0500
    From: Khushboo.Chokhani@bestbuy.com
    To: dbi-users@perl.org

    Hi,



    I have been stuck with this error since long now, and have tried almost
    everything available on web but no luckL

    Any help would be greatly appreciated.



    When I try to execute a PERL scripts I am getting an error:



    ORACLE_HOME=/u01/app/oracle/product/10.2.0

    TNS_ADMIN=/usr/local/tns

    Can't locate object method "connect" via package "DBI" at
    /opt/mabl/agg/dgt/batch-proc/contentdownload/PROD-BBY/bin/DeltaFlag.pm
    line 67.



    Before getting this error, I was getting an error where the script was
    not able to locate the DBI.pm module, hence I pointed my script to use
    the below path to locate DBI.pm:



    /u01/app/oracle/product/10.2.0/perl/lib/site_perl/5.8.3/Apache



    We are migrating from HPUX system to Linux, hence the scripts which we
    have been using since long are not working as is and they require some
    changes.



    Pls help!



    Thanks!



    Khushboo Chokhani

    Wipro Technologies
    Mobile : +1 (612)-354-1243



  • Jonathan Leffler at Sep 13, 2011 at 2:09 pm
    You have module Apache::DBI which ain't DBI. You need to install DBI (and DBD::Oracle), probably after compiling them.

    JL

    ------Original Message------
    From: Chokhani, Khushboo
    To: dbi-users@perl.org
    Subject: Need help with DBI connect
    Sent: Sep 12, 2011 08:18

    Hi,



    I have been stuck with this error since long now, and have tried almost
    everything available on web but no luckL

    Any help would be greatly appreciated.



    When I try to execute a PERL scripts I am getting an error:



    ORACLE_HOME=/u01/app/oracle/product/10.2.0

    TNS_ADMIN=/usr/local/tns

    Can't locate object method "connect" via package "DBI" at
    /opt/mabl/agg/dgt/batch-proc/contentdownload/PROD-BBY/bin/DeltaFlag.pm
    line 67.



    Before getting this error, I was getting an error where the script was
    not able to locate the DBI.pm module, hence I pointed my script to use
    the below path to locate DBI.pm:



    /u01/app/oracle/product/10.2.0/perl/lib/site_perl/5.8.3/Apache



    We are migrating from HPUX system to Linux, hence the scripts which we
    have been using since long are not working as is and they require some
    changes.



    Pls help!



    Thanks!



    Khushboo Chokhani

    Wipro Technologies
    Mobile : +1 (612)-354-1243








    Sent from my BlackBerry® smartphone, powered by CREDO Mobile.
  • Tiger peng at Sep 13, 2011 at 2:41 pm
    Mostly there are multiple perl, DBI, ... on your box.

    Check which perl is used; what is its version; what library paths are under this Perl; where is your DBI, where is the DBD::Oracle under the DBI. And then you need set the environment before call the script; or have the environment set in the BEGIN block (some time you may need to call back the script in the BEGIN block that set up the environment before use DBI).

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupdbi-users @
categoriesperl
postedSep 12, '11 at 3:18p
activeSep 13, '11 at 2:41p
posts4
users4
websitedbi.perl.org

People

Translate

site design / logo © 2022 Grokbase