note 37792 added to function.ocibindbyname

From: Date: Thu, 27 Nov 2003 10:14:22 +0000
Subject: note 37792 added to function.ocibindbyname
Groups: php.notes 
Request: Send a blank email to php-notes+get-61022@lists.php.net to get a copy of this message
If you use dba_tab_columns or user_tab_columns to get the sizes of the columns into which you are inserting data with OCIBindByName, be aware that a DATE type column is returned as 7 which is the size of it when it is stored in oracle's internal format. The problem arises when you are in fact inserting dates using the TO_DATE function as your bound data could be something like "28/04/1972 12:22.13" which is larger than the width specified in the bind statement and will get you the ever so helpful OCI error message of: ORA-01461: can bind a LONG value only for insert into a LONG column ---- Manual Page -- http://www.php.net/manual/en/function.ocibindbyname.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+37792 Delete -- http://master.php.net/manage/user-notes.php?action=delete+37792&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+37792&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#61022) next »