Re: [w3c/IndexedDB] Add note about sorting by code unit (#182)

> How does that work with cursors? ;-)

For actual content (not the database schema) you're stuck with either pulling it into memory and sorting (as you noted elsewhere), or coming up with a more complex key scheme. For example, if you wanted to sort by code point you could encode the string as UTF-32 into an Uint32Array and use that as the key. Code point isn't actually useful, of course. Looking at UTS10 I see _sort key_ defined, which sounds intriguingly like the right thing, but we're going beyond what I know.

(Anyway, https://github.com/w3c/IndexedDB/issues/38 is the right place for this discussion.)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/IndexedDB/pull/182#issuecomment-289127169

Received on Friday, 24 March 2017 19:53:42 UTC