Ver Mensaje Individual
  #5 (permalink)  
Antiguo 21/02/2011, 15:56
Avatar de SirDuque
SirDuque
 
Fecha de Ingreso: febrero-2009
Ubicación: Paso del Rey, Buenos Aires, Argentina
Mensajes: 975
Antigüedad: 15 años, 2 meses
Puntos: 89
Respuesta: Conectar & Consultar a Oracle... Tengo bases en MySQL[Asesoramiento]

Código PHP:
Ver original
  1. <?php
  2.  
  3. $conn = oci_connect('proovedor', '******', '200.68.***.***/TERMINAL.WORLD');
  4. if (!$conn) {
  5.     $e = oci_error();
  6.     trigger_error(htmlentities($e['message'], ENT_QUOTES), E_USER_ERROR);
  7. }
  8.  
  9. $stid = oci_parse($conn, 'SELECT department_id, department_name FROM departments');
  10. oci_execute($stid);
  11.  
  12. while (($row = oci_fetch_array($stid, OCI_BOTH))) {
  13.     // Use the uppercase column names for the associative array indices
  14.     echo $row[0] . " and " . $row['DEPARTMENT_ID']   . " are the same<br>\n";
  15.     echo $row[1] . " and " . $row['DEPARTMENT_NAME'] . " are the same<br>\n";
  16. }
  17.  
  18. oci_free_statement($stid);
  19. oci_close($conn);
  20.  
  21. ?>

Cita:
Fatal error: Call to undefined function oci_connect() in D:\back_up pendrive\root\oracle.php on line 10
__________________
Mono programando!
twitter.com/eguimariano