Using Pear's DB-class for ODBC against Oracle on Linux
| From: | Jakob Breivik Grimstveit | Date: | Mon, 28 Jun 2004 11:30:50 +0000 |
| Subject: | Using Pear's DB-class for ODBC against Oracle on Linux | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-13369@lists.php.net to get a copy of this message | ||
I have been trying to form a usable DSN for an Oracle-ODBC-connection
towards an Oracle database, but no luck so far :-(.
$dsn = 'odbc://' . DB_USERNAME . ':' . DB_PASSWORD . '@' . DB_NAME;
Using this does unfortunately not work. It responds with "unable to
connect".
Isn't ODBC working on Linux? Would like to use that instead of OCI8, if
possible.
System information:
[root@server root]# rpm -qa|grep -i odbc
unixODBC-2.2.3-6
unixODBC-devel-2.2.3-6
[root@server root]# uname -a
Linux server.starshipping.com 2.4.20-30.9 #1 Wed Feb 4 20:44:26 EST 2004
i686 i686 i386 GNU/Linux
[root@server root]# php -r 'phpinfo();'|grep Configure
Configure Command => './configure'
'--with-apxs=/usr/local/apache/bin/apxs' '--with-oci8=/my/oracle8'
'--with-config-file-path=/path/conf' '--enable-sigchild'
'--without-mysql' '--with-ldap' '--with-unixODBC'
[root@server root]# php -v|grep 4.3
PHP 4.3.7 (cli) (built: Jun 28 2004 10:18:53)
PHP compiled from source right now.
Thanks in advance.
--
Jakob Breivik Grimstveit, http://www.grimstveit.no/jakob, +47 48298152
System Integrator, Star Shipping AS, http://www.starshipping.com
Murphy's Law of Research:
Enough research will tend to support your theory.