

CREATE TABLE subscriptions (
	subscriber TEXT,
	feed TEXT,
	PRIMARY KEY (subscriber, feed)
);

CREATE TABLE beets (
	beetid INTEGER PRIMARY KEY AUTOINCREMENT,
	login TEXT NOT NULL,
	message TEXT,
	posttime DATETIME DEFAULT CURRENT_TIMESTAMP
);

INSERT INTO subscriptions (subscriber, feed) VALUES ('bugs', 'elmer');
INSERT INTO subscriptions (subscriber, feed) VALUES ('bugs', 'daffy');
INSERT INTO subscriptions (subscriber, feed) VALUES ('elmer', 'bugs');
INSERT INTO subscriptions (subscriber, feed) VALUES ('daffy', 'bugs');

INSERT INTO beets (login, message)
	VALUES ('bugs', "What's up, doc?");
INSERT INTO beets (login, message)
	VALUES ('elmer', "Shh. I'm hunting wabbits!");
INSERT INTO beets (login, message)
	VALUES ('bugs', "What do you mean, wabbits?");
INSERT INTO beets (login, message)
	VALUES ('elmer', "You know, with big wong ears, and a wittle white fwuffy tail, and he hops awound and awound!");
INSERT INTO beets (login, message)
	VALUES ('bugs', "Listen, Doc. Confidentially, I AM A WABBIT!");
