I've recently found out that the Ora_Fetch_Into function cannot get a small value of the tables data. We've tried to fetch other tables which have a large amount data ,and it succeeds. The queried values echoed successfully. Is there any idea why? im using PHP4.2.1 oracle7.3.3
Regards, Mike > thanks miguel but i've already checked it, i've included return values > checking where it stop. Here's my full source test script. > There where no Ora_Error_Code returned. > > <? > PutEnv("ORACLE_SID=PROD"); > PutEnv("ORACLE_HOME=/u01/app/oracle/product/7.3.3_prod"); > $connection = Ora_Logon("apps","apps"); > if($connection==false){ > echo Ora_ErrorCode($connection).":". Ora_Error($connection)."<BR>"; > exit; > } > $cursor= Ora_Open($connection); > if($cursor==false){ > echo Ora_ErrorCode($connection).":". Ora_Error($connection)."<BR>"; > exit; > } > $query = "select * from mikecarel"; > //$query = "select table_name from all_tables"; > $result = Ora_Parse($cursor,$query); > if($result==false){ > echo Ora_ErrorCode($connection).":". Ora_Error($connection)."<BR>"; > exit; > } > $result=Ora_Exec($cursor); > if($result==false){ > echo Ora_ErrorCode($connection).":". Ora_Error($connection)."<BR>"; > exit; > } > echo"<table border=1>"; > echo"<tr><td><b>Full Name</b></td><td><b>Email Address</b></td></tr>"; > //$values=array(mike, tess); > while(Ora_Fetch_Into($cursor,$values)){ > $name = $values[0]; > $email = $values[1]; > echo "<tr><td>$name</td><td>$email</td></tr>"; > echo "$email"; > print($name); > $result =1; > } > if(!$result==1) print("no result"); > echo"</table>"; > > ora_close($cursor); > ora_logoff($connection); > ?> > > > mike > > > > > Check the return values from your ora_logon, ora_open, ora_parse, and > > ora_exec calls to see whether they worked. That way you can know at > > which stage it stopped working. > > > > miguel > > > > On Mon, 27 May 2002, Michael P. Carel wrote: > > > Finally i've set-up my AIX server with PHP and oracle support. Thanks > for > > > all who helps me for the configure setup. > > > Now I have a problem in oracle function regarding the retrieval of > entries > > > in the oracle table. The Ora_Fetch_Into function doesnt work properly to > me > > > or i have an error in which i dont know. I've written below the code > that i > > > used to test, it doesnt echo the value of $name and $email. My query > works > > > if i've enter it manually with my Oracle server. I really dont know why > im > > > just a newbie with this database(oracle) statement. > > > > > > Please help us here. Thanks in advance. > > > > > > <?PutEnv("ORACLE_SID=PROD"); > > > PutEnv("ORACLE_HOME=/u01/app/oracle/product/7.3.3_prod"); > > > $connection = Ora_Logon("apps","apps"); > > > $cursor= Ora_Open($connection); > > > > > > $query = "select * from mikecarel"; > > > $result = Ora_Parse($cursor,$query); > > > $result=Ora_Exec($cursor); > > > echo"<table border=1>"; > > > echo"<tr><td><b>Full Name</b></td><td><b>Email Address</b></td></tr>"; > > > while(Ora_Fetch_Into($cursor,$values)){ > > > $name = $values[0]; > > > $email = $values[1]; > > > echo "<tr><td>$name</td><td>$email</td></tr>"; > > > } > > > ora_close($cursor); > > > ora_logoff($connection); ?> > > > > > > > > > > > > > > > > > > > > > > > > Regards, > > > mike > > > > > > > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php