All pastes #352400 Raw Edit

Someone

public text v1 · immutable
·published 2007-02-12 20:12 UTC
rendered paste body
CREATE TABLE `a_piccomments` (
  `cID` int(255) NOT NULL auto_increment,
  `cTo` varchar(15) NOT NULL,
  `cFrom` varchar(15) NOT NULL,
  `cContent` mediumblob NOT NULL,
  `cDate` timestamp NOT NULL default CURRENT_TIMESTAMP,
  PRIMARY KEY  (`cID`)
) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ;

cTo == ID of the picture the comment is for
cFrom = ID of the person the comment is from

CREATE TABLE `a_profiles` (
  `pID` int(15) NOT NULL,
  `pName` varchar(255) NOT NULL,
  `pAbout` mediumblob NOT NULL,
  `pInterests` mediumblob NOT NULL,
  `pMusic` mediumblob NOT NULL,
  `pFilm` mediumblob NOT NULL,
  `pTelevision` mediumblob NOT NULL,
  `pBooks` mediumblob NOT NULL,
  `pDefaultPic` int(16) NOT NULL default '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

pDefaultPic = ID of the picture they want to use as their default
ID1 = Default site pic


CREATE TABLE `a_pictures` (
  `pID` int(255) NOT NULL auto_increment,
  `pOwner` int(15) NOT NULL,
  `pPath` varchar(50) NOT NULL,
  PRIMARY KEY  (`pID`)
) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;

pID = 1 is the default site pic, and it has a pOwner of 0