note 3427 deleted from function.ocibindbyname by sixd

From: Date: Wed, 20 Nov 2013 19:46:49 +0000
Subject: note 3427 deleted from function.ocibindbyname by sixd
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-197581@lists.php.net to get a copy of this message
Note Submitter: benjy at nectaris dot com ---- Note that when binding a variable to a VARCHAR2 column, the length parameter should count an extra character (the terminating null.) For example, when binding to a column of type VARCHAR2(500), the length parameter should be 501. Otherwise when a string of length 500 is supplied as a bind value an error ("ORA-01480: trailing null missing from STR bind value") will be thrown. According to the OCI documentation this happens because the length parameter is used by OCI as a search limit for the terminating null in the underlying C/C++ character string.

« previous php.notes (#197581) next »