MailNews:Address Book SQLite design

From MozillaWiki
Revision as of 21:09, 22 November 2007 by Jcranmer (talk | contribs) (New page: This page is meant for planning out a redesign of the Address Book to use SQLite instead of MDB. See [https://bugzilla.mozilla.org/show_bug.cgi?id=11050 bug 11050] and [https://bugzilla.mo...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This page is meant for planning out a redesign of the Address Book to use SQLite instead of MDB. See bug 11050 and bug 382876 for other details.

Proposed schema:

CREATE TABLE Cards (
  CardKey INT NOT NULL PRIMARY KEY AUTOINCREMENT,
  [ xxx CHAR for all defined names in nsAddressBook.idl ]
);
CREATE TABLE OtherProperties (
  CardKey INT NOT NULL,
  Property CHAR NOT NULL,
  Value CHAR
);
CREATE TABLE Directories (
  DirKey INT NOT NULL PRIMARY KEY AUTOINCREMENT,
  Flags INT NOT NULL,
  Name CHAR,
  Description CHAR
);
CREATE TABLE DirectoryMap (
  DirKey INT NOT NULL,
  CardKey INT NOT NULL
);