#
# Table structure for table 'tx_p123'
#
CREATE TABLE tx_p123 (
	uid int(11) DEFAULT '0' NOT NULL auto_increment,
	pid int(11) DEFAULT '0' NOT NULL,
	tstamp int(11) unsigned DEFAULT '0' NOT NULL,
	crdate int(11) unsigned DEFAULT '0' NOT NULL,
	fe_cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
	hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
	deleted tinyint(4) unsigned DEFAULT '0' NOT NULL,
	
	ip varchar(20) DEFAULT '0.0.0.0' NOT NULL,
	hash varchar(32) DEFAULT '' NOT NULL,
	poster tinytext,
	preview blob,
	poster_later tinyint(4) unsigned DEFAULT '0' NOT NULL,
	poster_description text,
	poster_required tinyint(4) unsigned DEFAULT '0' NOT NULL,
	
	postercount tinyint(4) unsigned DEFAULT '0' NOT NULL,
	spare tinyint(4) unsigned DEFAULT '0' NOT NULL,
	additional int(11) unsigned DEFAULT '0' NOT NULL,
	
	PRIMARY KEY (uid),
	KEY parent (pid)
);

#
# Table structure for table 'tx_p123_cache'
#
CREATE TABLE tx_p123_cache (
	md5hash varchar(32) DEFAULT '' NOT NULL,
	md5city varchar(32) DEFAULT '' NOT NULL,
	fileinfo blob,
	expires int(11) DEFAULT '0' NOT NULL,
	
	PRIMARY KEY (md5hash),
	KEY parent (md5city)
) ENGINE=InnoDB;

#
# Table structure for table 'tx_p123_later'
#
CREATE TABLE tx_p123_later (
	link varchar(32) DEFAULT '' NOT NULL,
	pid int(11) DEFAULT '0' NOT NULL,
	deleted int(11) unsigned DEFAULT '0' NOT NULL,
	expires int(11) DEFAULT '0' NOT NULL,
	
	sid int(11) DEFAULT '0' NOT NULL,
	hash varchar(32) DEFAULT '' NOT NULL,
	format varchar(16) DEFAULT '' NOT NULL,
	lastname varchar(80) DEFAULT '' NOT NULL,
	firstname varchar(80) DEFAULT '' NOT NULL,
	company varchar(80) DEFAULT '' NOT NULL,
	email varchar(80) DEFAULT '' NOT NULL,
	
	PRIMARY KEY (link),
	KEY parent (pid)
);