PHP Oracle Hosting
PHP Oracle Connections (oci)
Oracle Instant Client with oci are enabled at account set up.
To test your connection, you can use the PHP script below.
<?php
$conn = oci_connect('SchemaName', 'SchemaPassword', '//hostname/SID');
$query = 'select sysdate from dual';
$stid = oci_parse($conn, $query);
oci_execute($stid, OCI_DEFAULT);
while ($row = oci_fetch_array($stid, OCI_ASSOC)) {
foreach ($row as $item) {
echo $item." ";
}
echo "<br>\n";
}
oci_free_statement($stid);
oci_close($conn);
?>
Please note that pdo_oci is also enabled.
For pdo_oci example, please see FAQ:
http://faq.enciva.com/content/6/48/en/is-pdo_oci-available-for-oracle.html
If you have any questions, please raise a support ticket
Tags: -
Related entries:
- Can you map my APEX application to my domain?
- Video Tutorials
- Oracle Backups
- How do I connect via SQL Developer?
- Can I connect via SQL Developer, PLSQL Developer, Toad, ....
Author: EncivaFAQ
Revision: 1.1
You cannot comment on this entry