note 76970 rejected from function.ocifetchinto by nlopess

From: Date: Wed, 08 Aug 2007 15:10:47 +0000
Subject: note 76970 rejected from function.ocifetchinto by nlopess
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-129338@lists.php.net to get a copy of this message
Note Submitter: zillo at lycos dot es ---- I have a datetime field in ORACLE, but, when i use the array results variable i only receive the date "30/12/99" (1899-12-30). I'm trying with OCIFethcInto and OCIFetchStatement but i'm not able to obtain a valid result. my code: <? $sql="SELECT * FROM PRESENCI"; $sql.=" WHERE CodPers = '00003' "; $sql.=" AND Fecha >= '06/08/2007' "; $sql.=" AND Fecha <= '08/08/2007' "; $sql.=" ORDER BY Fecha"; $sql=OCIParse($con, $sql); OCIExecute($sql); if (!OCIFetchInto($sql, $rec, OCI_ASSOC + OCI_RETURN_NULLS)) exit; $horario=$rec["HORTEO"]; //HORTEO: field name echo $horario; ?> It should return "30/12/99 8:00:00", but i only get "30/12/99". Any suggestions ? Thanks!

« previous php.notes (#129338) next »