From: Jim Starkey Date: December 15 2008 5:48pm Subject: Re: Falcon Index Keys List-Archive: http://lists.mysql.com/falcon/313 Message-Id: <49469856.3060308@nimbusdb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Vladislav Vaintroub wrote: > Common memcmp'rable index format is probably the best sweet spot of Falcon I > can think of, from developers point of view. > Considering binary representation while doing sort/search/key compression > was a big pain in the back for me at the time I have done it for various > archaic Adabas datatypes (alphanumeric ASCII and EBCDIC , binary integer > types in big and little endian , Unicode(UTF8), packed, unpacked and fixed > decimal, IEEE float and double) > > I think I would not map all numbers to double though if I'd be doing that > from scratch ;) , it is a strange imprecise format. > > It isn't imprecise over the range of numbers that people actually use. Double has 56 bits of binary precision (if I remember correctly), which is a lot. There just aren't a lot of things in the world worth tracking that there are 2**56 of. And if there were, it would still give sufficient selectivity to be useful. More importantly, however, is that doubles are independent of physical type, so indexes don't have to be rebuilt when a field's data type or scale factor is changed. Since Falcon was designed for online change anything, this was a major consideration. -- Jim Starkey President, NimbusDB, Inc. 978 526-1376