[ms4w-users] Problem With Oracle 8.1.7
Abul Kashem Md. Hasan
ahasan at cegisbd.com
Thu Nov 9 01:03:20 EST 2006
Dear All,
I am using Oracle 8.1.7, PHP 5.1.4, Apache 2.0.58 and windows 2000
Professional. I uncomment extension=php_oci8.dll in php.ini file and restart
apache service.
I am trying to connect with oracle using following scripts.
<?php
$dbh = OCILogon( "akm", "akm", "localhost:1521/aris" );
if ($dbh == NULL) {
print "DB Connection Error!!";
} else {
$sql = "SELECT * FROM datagroup";
$stmt = OCIParse($dbh, $sql);
if (!$stmt) {
print "DB Search Error!!";
} else {
OCIExecute($stmt);
$rows = OCIFetchstatement($stmt, $results);
if ($rows > 0) {
for ($i = 0; $i < $rows; $i++) {
print $results["Datagroupid"][$i] . "<br>";
}
}
}
OCIFreeStatement($stmt);
OCILogoff($dbh);
}
?>
But I got following error messages.
Fatal error: Call to undefined function OCILogon() in
D:\ARISORA\web\untitled1.php on line 10
The OCI.dll file is in C:\oracle\ora81\bin and this path is added in
Environment Variable PATH. I attached my php.ini, httpd.conf and
phpinfo.html files.
Please help me to sovle this problem.
Regards.
Abul Kashem Md. Hasan
Associate Specialist, Database/IT
Center for Environmental and Geographic Information Services (CEGIS)
House # 6, Road # 23/C
Gulshan - 1, Dhaka - 1212
Phone: 8821570-2, 8817648 - 52, Ext-501
email: ahasan at cegisbd.com
Web: http://www.cegisbd.com
More information about the ms4w-users
mailing list