Advertisement
Guest User

Untitled

a guest
May 29th, 2015
229
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.33 KB | None | 0 0
  1. CREATE TABLE `user` (
  2. `UserId` int(255) NOT NULL DEFAULT '0',
  3. `UserName` varchar(50) DEFAULT NULL,
  4. `UserDOB` date DEFAULT NULL,
  5. `UserBio` longtext,
  6. `UserReputation` int(100) DEFAULT NULL,
  7. `UserPassword` varchar(100) DEFAULT NULL,
  8. `UserRole` varchar(10000) DEFAULT NULL,
  9. `profilepicture` blob,
  10. `UserEmail` varchar(50) DEFAULT NULL,
  11. PRIMARY KEY (`UserId`)
  12. )
  13. CREATE TABLE `tag` (
  14. `tagID` int(11) NOT NULL DEFAULT '0',
  15. `tagContent` varchar(100) DEFAULT NULL,
  16. `tagCount` int(11) DEFAULT NULL,
  17. PRIMARY KEY (`tagID`)
  18. )
  19. CREATE TABLE `posttagrelation` (
  20. `postID` int(11) NOT NULL DEFAULT '0',
  21. `tagID` int(11) NOT NULL DEFAULT '0',
  22. PRIMARY KEY (`postID`,`tagID`)
  23. )
  24. CREATE TABLE `postcategoryrelation` (
  25. `postID` int(11) NOT NULL DEFAULT '0',
  26. `categoryID` int(11) NOT NULL DEFAULT '0',
  27. PRIMARY KEY (`postID`,`categoryID`)
  28. )
  29. CREATE TABLE `post` (
  30. `postID` int(11) NOT NULL DEFAULT '0',
  31. `postTitle` varchar(100) DEFAULT NULL,
  32. `postContent` mediumtext,
  33. `postAuthor` varchar(100) DEFAULT NULL,
  34. `postDate` date DEFAULT NULL,
  35. `postUpvote` int(11) DEFAULT NULL,
  36. `postDownvote` int(11) DEFAULT NULL,
  37. `postViewCount` int(11) DEFAULT NULL,
  38. PRIMARY KEY (`postID`)
  39. )
  40. CREATE TABLE `follow` (
  41. `userID` int(11) NOT NULL DEFAULT '0',
  42. `followingID` int(11) NOT NULL DEFAULT '0',
  43. PRIMARY KEY (`userID`,`followingID`)
  44. )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement