Note: You are currently viewing documentation for Moodle 3.6. Up-to-date documentation for the latest stable version of Moodle is likely available here: Installing Oracle for PHP.

Installing Oracle for PHP

From MoodleDocs
Revision as of 03:03, 14 November 2007 by Martin Langhoff (talk | contribs)

Note: This page is a work-in-progress. Feedback and suggested improvements are welcome. Please join the discussion on moodle.org or use the page comments.




Important Note: Don't forget to enable this variable in your php.ini (or .htaccess) file:

(else, all your data will be escaped following MySQL rules, that are incorrect for Oracle)

   magic_quotes_sybase = On


Broken versions of OCI8 driver

PHP v5.2.4 (and perhaps v5.2.3 as well) have shipped with a bug in the OCI8 driver that leaks statement handles. The version of the OCI8 driver with the bug is v1.2.4. Possible workarounds:

  • Downgrade to PHP v5.2.1 (reported to work)
  • Downgrade only the oci8 driver to the one included in PHP 5.2.1 (does this work?)
  • If you are on linux and/or can compile PECL extensions, install an older OCI8 driver (v1.2.3 seems to work) from the PECL repository http://pecl.php.net/package/oci8

More information at

Related links

Installing MSSQL for PHP