http://qs321.pair.com?node_id=11139073


in reply to Unable to connect to Oracle 19c

note that your $dsn is not used in your DBI->connect() which hardcodes the dsn.

Check if DBD::Oracle is installed under a path included in @INC. In Linux I use App::whichpm to locate modules from the command prompt, like: whichpm DBD::Oracle . In order to see Perl's @INC I do this from command prompt: perl -e "print \"@INC\"" (I guess that works in windows with lame quoting rules). Simply check if the starting path of the first command matches an entry in the output of the second.

Finally, as you said and other Monks said and the program diagnosed: Perhaps the capitalisation of DBD 'oracle' isn't right. And also the documentation of DBD::Oracle has this example (and that should have been your first call actually!):

use DBI; $dbh = DBI->connect("dbi:Oracle:$dbname", $user, $passwd);

Also note that more than one reasons for failure may apply.

bw, bliako