tracker issue : CF-4202452

select a category, or use search below
(searches all categories and all time range)
Title:

[ANeff] Bug for: lack of String member functions on NULL creates backward-compat issue

| View in Tracker

Status/Resolution/Reason: Closed/Withdrawn/AsDesigned

Reporter/Name(from Bugbase): Aaron Neff / ()

Created: 05/16/2018

Components: Language, Null Support

Versions: 2018

Failure Type: Usability Issue

Found In Build/Fixed In Build: 2018.0.01.308605 (PreRelease) /

Priority/Frequency: Normal / Some users will encounter

Locale/System: / Platforms All

Vote Count: 0

Issue: lack of String member functions on NULL creates backward-compat issue

1) query data type is long-existing
2) pre-Aether, cfquery auto-converted NULL to string
3) member functions have existed since CF11 (4 years; 2 full releases)
4) Aether's NULL lacks String member functions

This creates a backward-compat issue for modern code using String member functions on query values.

Example, consider:

5) isNULL() always returned false for query values..
6) ..so len()/trim(len()) was used instead..
7) ..which equate to .len()/.trim().len()..
8) ..which fail in Aether w/ NULL support enabled

And that's not even considering code that does _other stuff_ with stringy query values using member functions.

Attachments:

Comments:

Existing code is not expected to work out of the box with Null Support turned on.  Lack of string member functions, is just one use-case that demonstrates the discrepancy. There are bound to be a large number of old code bases that do not work as expected the moment null support is turned on.  This was the reasoning behind ensuring backward compatibility is intact by providing an option to turn off Null Support. 
Comment by Immanuel N.
27838 | May 17, 2018 09:19:22 AM GMT
Hi Immanuel, The problem is _CURRENT_ code bases (member functions are only 4 years old). Thanks!, -Aaron
Comment by Aaron N.
27881 | May 19, 2018 09:02:13 AM GMT
The "Use the member functions" doc says: "You can now start coding in a true object oriented style." Indeed, member functions were sold as syntactic sugar. And now code bases that have already upgraded to member functions in the last 4yr, and using those on query values, are gonna crash-n-burn when NULL is enabled.
Comment by Aaron N.
27882 | May 19, 2018 09:07:22 AM GMT
To state that this is a non-issue is to admit that customers aren't using features added in the last 2 releases. Checkmate either which way.
Comment by Aaron N.
27883 | May 19, 2018 09:15:59 AM GMT