RE: [PEAR] Re: MDB2 with oci8 DSN

From: Date: Fri, 26 Sep 2008 11:37:09 +0000
Subject: RE: [PEAR] Re: MDB2 with oci8 DSN
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-29299@lists.php.net to get a copy of this message
No, still can't connect. You've got //localhost/XE in your example, how should my host be formatted? Why is the array syntax safer btw? -----Original Message----- From: Lorenzo Alberton [mailto:l.alberton@quipo.it] Sent: 26 September 2008 12:17 To: Ryan Taylor Cc: pear-general@lists.php.net Subject: [PEAR] Re: MDB2 with oci8 DSN Ryan Taylor wrote: > I'm having trouble connecting to am oracle database using MDB2. I've > installed oci8 extension for PHP and think that is working. I've also > installed the MDB2_Driver_oci8. try with the array syntax, it's safer: $dsn = array( 'phptype' => 'oci8', 'hostspec' => '//localhost/XE', 'username' => 'hr', 'password' => 'oracle', //'hostspec' => '127.0.0.1:1521', ); or //oracle's "Easy Connect" syntax (Oracle 10g) $dsn = array ( 'phptype' => 'oci8', 'dbsyntax' => 'oci8', 'username' => 'XXXX', 'password' => 'YYY', 'protocol' => 'tcp', 'hostspec' => '//localhost/XE', 'service' => 'servicename', 'port' => false, 'socket' => false, 'database' => false, 'mode' => false, ); HTH Cheers, -- Lorenzo Alberton http://pear.php.net/user/quipo ________________________________________________________________________ Quipo Free Internet: sicuro e veloce senza costi di attivazione e senza canone, 2 e-mail da 50 Mb, 150 Mb di spazio web e molto di più! Registrati gratis: http://www.quipo.it -- PEAR General Mailing List (http://pear.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.pear.general (#29299) next »