~barry/mailman/events-and-web

« back to all changes in this revision

Viewing changes to src/mailman/database/schema/sqlite_20121015000000_01.sql

  • Committer: Barry Warsaw
  • Date: 2012-10-16 22:40:12 UTC
  • Revision ID: barry@list.org-20121016224012-xxrd5zgkwdrmh9y4
Database
--------
 * The `ban` table now uses list-ids to cross-reference the mailing list,
   since these cannot change even if the mailing list is moved or renamed.

Interfaces
----------
 * The `IBanManager` is no longer a global utility.  Instead, you adapt an
   `IMailingList` to an `IBanManager` to manage the bans for a specific
   mailing list.  To manage the global bans, adapt ``None``.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
-- THIS FILE CONTAINS THE SQLITE3 SCHEMA MIGRATION FROM
 
2
-- 3.0b2 TO 3.0b3
 
3
--
 
4
-- AFTER 3.0b3 IS RELEASED YOU MAY NOT EDIT THIS FILE.
 
5
 
 
6
-- REMOVALS from the ban table.
 
7
-- REM mailing_list
 
8
 
 
9
-- ADDS to the ban table.
 
10
-- ADD list_id
 
11
 
 
12
CREATE TABLE ban_backup (
 
13
    id INTEGER NOT NULL,
 
14
    email TEXT,
 
15
    PRIMARY KEY (id)
 
16
    );
 
17
 
 
18
INSERT INTO ban_backup SELECT
 
19
    id, email
 
20
    FROM ban;
 
21
 
 
22
ALTER TABLE ban_backup ADD COLUMN list_id TEXT;