From my naive understanding, memcmp() is used to efficiently compare long 
strings of bytes. But where in SQLite3 is it necessary to compare long strings 
of floating point numbers? I, of course, can imagine SQL queries plucking 
single floating point values from rows or indexes, but I can’t imagine where 
the long strings would be. Could you enlighten me?


> On Apr 3, 2019, at 3:23 PM, Lifepillar <[email protected]> wrote:
> 
> 
> 
>> On 3 Apr 2019, at 20:04, Joshua Thomas Wise <[email protected]> 
>> wrote:
>> 
>>> [Here, I must thank Dr. Hipp, with whom I had a brief email exchange
>>> severals moons ago, who convinced me that the IEEE 754 encoding was not
>>> an ideal storage format for databases]
>> 
>> I’m curious, what were the reasons behind Dr. Hipp’s opinion on this?
> 
> At the time of SQLite4, I wrote to him asking why he had dismissed IEEE
> 754 as a storage format in favor of a custom encoding. His answer was
> that he wanted comparisons to be performed using memcmp(), which IEEE
> 754 does not allow. 
> 
> There may have been other reasons (complexity, range, ...), but that one
> stuck with me and prompted me to start searching for order-preserving
> encodings.
> 
> Life.
> _______________________________________________
> sqlite-users mailing list
> [email protected]
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to