W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2010

Re: [IndexedDB] Compound and multiple keys

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Wed, 1 Dec 2010 17:19:53 -0800
Message-ID: <AANLkTik9y1KaczKowD=U+oY2-1Tkbfa-d1r6z0KrdBSn@mail.gmail.com>
To: Jonas Sicking <jonas@sicking.cc>
Cc: Webapps WG <public-webapps@w3.org>
Disclaimer: all of my db experience is with SQL.

I prefer option A.  It's simple and easy.  Option B requires you to
potentially duplicate information into an array to use as a key, which
I don't like.

That said, I don't have much experience with out-of-line keys.  Can we
combine A & B such that in-line keys are A and out-of-line keys are B?
 That seems to be intuitive.

To answer your specific questions, I've never used a compound key with
variably numbers of columns.  (Disclaimer: I'm strongly in the
synthetic-key camp, so I don't really use compound keys anyway.  But
I've never seen an instance where I would have wanted to use a
variable number of columns, were I to index the table with a compound

I can't distinguish your second question from the first.

For your third question, the closest analogue in SQL to an array is a
SET.  I can't tell whether or not SETs can be used as keys.

Received on Thursday, 2 December 2010 01:20:45 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 18:13:14 UTC