<html>
<title>Demo:
<?php echo $PHP_SELF; ?></title>
<body bgcolor="white">
<h1>
<?php echo $PHP_SELF; ?></h1>
<hr>
<!-- Demo begin -->
<?php
// Connect to Oracle using SID= $ORACLE_SID og $TWO_TASKS
$con = OCILogon(
"scott",
"tiger");
// Get users tables
$sql =
"select distinct tabs.table_name from user_tables tabs";
echo
"SQL: ".$sql;
echo
"<p>\n";
$stmt = OCIParse($con, $sql);
OCIExecute($stmt);
while (OCIFetchInto($stmt, &$result, OCI_ASSOC)) {
echo $result[
'TABLE_NAME'];
echo
"<br>\n";
}
// Disconnect from Oracle
OCILogoff($con);
?>
<!-- Demo end -->
<hr>
<i>by Hans Schou <a href="mailto:chlor@schou.dk"><chlor@schou.dk></a></i>
<a href="http://www.schou.dk">http://www.schou.dk</a>
<br>
<?php
// Display source file if exists
if (file_exists($fn = basename($PHP_SELF.
"s")))
echo
"<i>Source file: <a href=\"".$fn.
"\">$fn</a></i>\n";
else
echo
"<i>Source file $fn is not available</i>\n";
?>
</body>
</html>