Richard Hipp <drh-czdrofg0bjidnm+yrof...@public.gmane.org> writes: > The keys are encoded (see > http://www.sqlite.org/src4/doc/trunk/www/key_encoding.wiki) in a way > that causes a lexicographical ordering of the keys to correspond to > what the user wants out of ORDER BY.
The first paragraph mentions that the encoding allows comparison of keys with memcmp(), which makes it sound like an entire key -- meaning the concatenation of several values -- can be be compared in one operation against another key. The second paragraph notes: ,---- | Keys are compared value by value, from left to right, until a difference | if found. The first difference determines the key order. `---- Does "value by value" here mean that before comparison takes place, the key must be split apart into values, and then each pairwise value from each of the two keys can be compared with one call to memcmp() for each pair of values, or does "value by value" mean simply that the concatenated values' bytes will be compared from left to right, with one call to memcmp() for the entire key? -- Steven E. Harris _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users