#
# $Id: mysql_schema,v 1.3 2003/08/29 16:18:45 jamie Exp $
#

DROP TABLE IF EXISTS yass_sites;
CREATE TABLE yass_sites (
	id MEDIUMINT UNSIGNED NOT NULL auto_increment,
	sid char(16) NOT NULL,
	url varchar(250) NOT NULL,
	rdf varchar(250) NOT NULL,
	created datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
	touched datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
	failures MEDIUMINT UNSIGNED DEFAULT 0 NOT NULL,
	bid char(32) NOT NULL,
	UNIQUE sidurl (sid, url),
	PRIMARY KEY (id)
) TYPE = InnoDB;

# Commented out because target table is necessarily MyISAM,
# and MySQL FOREIGN KEY does not work across the InnoDB-MyISAM
# border as of this writing (July 2003).
# ALTER TABLE yass_sites ADD FOREIGN KEY (sid) REFERENCES stories(sid);

