Jump to content

Is this a PHP issue?


iPixel

Recommended Posts

I run this query in TOAD ( database management application ) and it returns to me the date that a specified table was last updated.

 

			$qry = "SELECT to_char(LAST_DDL_TIME, 'MM/DD/YYYY') AS LASTUPDATED FROM all_objects WHERE owner = 'USER' AND object_name = 'TABLENAME'";
			$go = oci_parse($conn, $qry);
			oci_execute($go);
			$result = oci_fetch_assoc($go)

			echo = $result['LASTUPDATED'];

 

However when i run that identical query through PHP i get absolutely NOTHING.

 

Any idea if perhaps PHP isnt capable of retreiving such data or if maybe i'm doing something wrong.

 

Thanks!

Link to comment
Share on other sites

echo = $result['LASTUPDATED'];

 

^^^ That's invalid php and produces a fatal parse error.

 

Are you developing and debugging your code on a system with error_reporting set to E_ALL and display_errors set to ON in your master php.ini so that all the errors php detects will be reported and displayed? You will save a TON of time.

Link to comment
Share on other sites

Yea i'm an idiot i constantly omit using error_reporting.

 

However... i placed this code above it all..

error_reporting(E_ALL);
ini_set('display_errors','On');

 

And the page still comes up blank... no errors reported it seems.

Link to comment
Share on other sites

Are you developing and debugging your code on a system with error_reporting set to E_ALL and display_errors set to ON in your master php.ini so that all the errors php detects will be reported and displayed? You will save a TON of time.

 

Your code never runs when there is a fatal parse error and those two lines of code are never executed.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.