Bet I know the answer to this, but there's no magi...
# cfml-general
d
Bet I know the answer to this, but there's no magic flag/QoQ setting to make QoQ NOT case sensitive, is there? State of the art is WHERE UPPER(sqlValue) = uCase(valueToSearchFor)?
b
@Dave Merrill Correct. You have to use upper or lower
šŸ‘ 1
I considered when I was revamping the Lucee QoQ to either • make text compare case insensitive by default • add a flag but I was concerned about the performance of potentially many thousands of
String.toUpperCase()
methods and I wasn't sure where a setting would go.
Plus, Adobe CF is case sensitive so anything Lucee did differently would be a potentially breaking difference
āœ… 1
t
I was unaware that this was a thing... That's so weird, because generally, neither CF nor SQL are case-sensitive.
b
Yeah, it always puzzled me why QoQ did this from the get-go. My guess was either performance or an oversight šŸ˜†
m
I've run into many strange issues due to QoQ case-sensitivity, especially if the case is different between select clause and order by clause.
b
In Lucee, or Adobe CF?
a
If I was to guess at the reason for the case sensitivity... QoQ was added in CFMX6... which was written by Java devs. And Java is... case sensitive. Probably didn't occur to anyone doing the dev work that CFML isn't case-sensitive by default. The 6 dev cycle was a bit of a shambles (it wasn't really usable until 6.1; it was kinda usable after 6.0's third update), so would not surprise me if the testing of new stuff was very thorough.
ā¤ļø 1