Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

Re^3: Environmental Variables and DBD::Oracle

by valavanp (Curate)
on Sep 25, 2006 at 08:53 UTC ( #574702=note: print w/replies, xml ) Need Help??

in reply to Re^2: Environmental Variables and DBD::Oracle
in thread Environmental Variables and DBD::Oracle

Hi dhj, Please try this. I suggest you to give the environment variable for oracle home like below.
#!/usr/perl5/5.8.4/bin/perl -w BEGIN { use lib "Your DBD Oracle module installation path"; use DBI; use DBD::Oracle; $ENV{"ORACLE_HOME"} ='/local/src/local.perl/oracle/instantclient_10 +_ +2'; } my $host = ""; my $sid = "AAAA"; my $user = 'secret'; my $passwd = 'evenmoresecret'; my $dbh = DBI->connect("dbi:Oracle:host=$host;sid=$sid", $user, $passw +d) || print ("database connection not made"); $dbh->disconnect;</p>
The above code is not executed, but it works well in my server and module installation path.

Updated by Steve_p - added code tags

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://574702]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (2)
As of 2017-08-19 05:51 GMT
Find Nodes?
    Voting Booth?
    Who is your favorite scientist and why?

    Results (310 votes). Check out past polls.