#44099 [Opn->Bgs]: PHP should treat NULL values like SQL does
| From: | johannes@php.net | Date: | Mon, 11 Feb 2008 21:19:38 +0000 |
| Subject: | #44099 [Opn->Bgs]: PHP should treat NULL values like SQL does | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-122186@lists.php.net to get a copy of this message | ||
ID: 44099
Updated by: johannes@php.net
Reported By: zy at adels dot zp dot ua
-Status: Open
+Status: Bogus
Bug Type: Feature/Change Request
Operating System: All
PHP Version: 5.2.5
New Comment:
Sorry, that would be a major change of the language desing which can't
be done.
Previous Comments:
------------------------------------------------------------------------
[2008-02-11 15:45:46] zy at adels dot zp dot ua
Description:
------------
Currently NULL values when used as arguments of math and comparision
operations are simply converted to zero. So there is no difference
between using NULL, false, 0 - this is a useless redundancy while
important functionality is missing - to tread NULL values as SQL treats
them.
For example:
NULL * $anything should be NULL, instead of 0
NULL + $anything should be NULL, instead of $anything
NULL == NULL should be false, while NULL === NULL should be true
If PHP has NULL value it should be used properly.
Expected result:
----------------
see above
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=44099&edit=1