Bug #70988 [Fbk->Csd]: preapared statements not doing the job
| From: | birger at bredelund dot dk | Date: | Sat, 28 Nov 2015 18:14:53 +0000 |
| Subject: | Bug #70988 [Fbk->Csd]: preapared statements not doing the job | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-197477@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=70988&edit=1
ID: 70988
User updated by: birger at bredelund dot dk
Reported by: birger at bredelund dot dk
Summary: preapared statements not doing the job
-Status: Feedback
+Status: Closed
Type: Bug
Package: MySQLi related
Operating System: win7
PHP Version: Next Minor Version
Block user comment: N
Private report: N
New Comment:
Sorry, but this is not correct.
Had a lot of problems with the database, but this issue is solved.
Somebody used $string[$idx]='' to remove start and finishing quotes from the string sent
to database.
Doesn't show up when string is printed on screen, but the "null-characters" are still
there - in the string in php and also in the data stored in the database.
So everything is actually functioning as intended - just not as expected, and it doesn't look
right.
Very sorry for the inconvenience.
Previous Comments:
------------------------------------------------------------------------
[2015-11-28 00:58:43] requinix@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.
A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc. If the script requires a
database to demonstrate the issue, please make sure it creates
all necessary tables, stored procedures etc.
Please avoid embedding huge scripts into the report.
------------------------------------------------------------------------
[2015-11-27 20:35:12] birger at bredelund dot dk
Description:
------------
---
From manual page: http://www.php.net/mysqli-stmt.bind-param
---
preapared statements can not update single characters - varchar(1) - or enum constructed from single
charaters.
No error is reported - neitehr stsmt nor mysqli objects - database is simply not updated.
PHP 5.5.12 (wamp 2.4.9)
Had to change db-definitions to use varchar(2) insted.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=70988&edit=1