in reply to ERROR: 1804 '(UNKNOWN OCI STATUS 1804) OCIInitialize

versions: perl : 5.6.1 DBI : 1.21 DBD : 1.12

Without knowing much about oracle, my first approach would be to try non-ancient versions of everything (perl 5.6.1. is more than 9 years old, DBD::Oracle 1.12 is so old that the search.cpan.org interface doesn't show it anymore, DBI 1.21 is also at least 4 years old).

Many problems have been fixed since the Auld Days, and yours might (mind you, might, not "is") be one of them.

Perl 6 - links to (nearly) everything that is Perl 6.

Replies are listed 'Best First'.
Re^2: ERROR: 1804 '(UNKNOWN OCI STATUS 1804) OCIInitialize
by peter_knight_99 (Initiate) on Jan 07, 2011 at 13:27 UTC

    I recently came across this problem when using various Oracle installs and the Oracle::DBD that was located there.

    I had two installs - an Oracle 10g & and Oracle 11g. The perl libraries I was using were the ones installed with Oracle 11g.

    When the perl program ran without altering the ORACLE_HOME env variable ( $ENV{ORACLE_HOME} ) , this worked fine.

    However, if the $ENV{ORACLE_HOME} was set within the perl program to use the Oracle 10g, then I got this error message.

    A simple trace on the database showed that this perl client wasn't connecting, so the problem had to be in the client, not the database.

    Now error message ORA-01804 suggests that the client couldn't find the timezone information - it normally expects to find it in $ORACLE_HOME/oracore/zoneinfo/timezlrg.dat.

    For my Oracle 11g install, this file wasn't present.

    However, the location of this file can be altered using the environment variable ORA_TZFILE ( Oracle support note ID 365558.1 discusses this), so by setting this environment variable, I could get my test programs to work correctly.

    Hope this helps.

      $ORACLE_HOME/oracore/zoneinfo/timezlrg.dat...

      I haven't worked much with oracle but I didn't think it was this ridiculous