Difference between revisions of "User:Woozle/Snorp/design/snorp story"

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
Jump to navigation Jump to search
(starting to sketch this out)
 
(more)
 
Line 6: Line 6:
 
  CREATE TABLE `snorp_story` (
 
  CREATE TABLE `snorp_story` (
 
   `ID`                INT NOT NULL AUTO_INCREMENT,
 
   `ID`                INT NOT NULL AUTO_INCREMENT,
    
+
   ID_USER            INT NOT NULL COMMENT "every Story is owned by a User; Users can have zero or more Stories",
 +
  Title              VARCHAR(64) NOT NULL COMMENT "title for use in lists and page headers",
 +
  Summary            // currently arguing with myself about how this should work
 
   PRIMARY KEY(`ID`)
 
   PRIMARY KEY(`ID`)
 
  )
 
  )
 
  ENGINE = MYISAM;
 
  ENGINE = MYISAM;
 
</mysql>
 
</mysql>

Latest revision as of 16:40, 28 June 2015

About

  • Purpose: each record is the root node for a Story.

SQL

<mysql>

CREATE TABLE `snorp_story` (
  `ID`                INT NOT NULL AUTO_INCREMENT,
  ID_USER             INT NOT NULL COMMENT "every Story is owned by a User; Users can have zero or more Stories",
  Title               VARCHAR(64) NOT NULL COMMENT "title for use in lists and page headers",
  Summary             // currently arguing with myself about how this should work
  PRIMARY KEY(`ID`)
)
ENGINE = MYISAM;

</mysql>