mooctest_user.sql 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. /*
  2. Navicat Premium Data Transfer
  3. Source Server : cxz
  4. Source Server Type : MySQL
  5. Source Server Version : 50720
  6. Source Host : localhost
  7. Source Database : mooctest_user
  8. Target Server Type : MySQL
  9. Target Server Version : 50720
  10. File Encoding : utf-8
  11. Date: 02/14/2018 16:04:18 PM
  12. */
  13. SET NAMES utf8;
  14. SET FOREIGN_KEY_CHECKS = 0;
  15. -- ----------------------------
  16. -- Table structure for `medal`
  17. -- ----------------------------
  18. DROP TABLE IF EXISTS `medal`;
  19. CREATE TABLE `medal` (
  20. `id` bigint(20) NOT NULL AUTO_INCREMENT,
  21. `name` varchar(255) DEFAULT NULL,
  22. `description` varchar(255) DEFAULT NULL,
  23. `img_url` varchar(255) DEFAULT NULL,
  24. `type` bigint(20) NOT NULL,
  25. `is_deleted` bit(1) NOT NULL,
  26. `create_time` datetime DEFAULT NULL,
  27. PRIMARY KEY (`id`)
  28. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  29. -- ----------------------------
  30. -- Table structure for `user_2_integral`
  31. -- ----------------------------
  32. DROP TABLE IF EXISTS `user_2_integral`;
  33. CREATE TABLE `user_2_integral` (
  34. `id` bigint(20) NOT NULL AUTO_INCREMENT,
  35. `user_id` bigint(20) NOT NULL,
  36. `points` bigint(20) DEFAULT NULL,
  37. `type` bigint(20) DEFAULT NULL,
  38. `source` varchar(255) DEFAULT NULL,
  39. `create_time` datetime DEFAULT NULL,
  40. PRIMARY KEY (`id`)
  41. ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;
  42. -- ----------------------------
  43. -- Table structure for `user_2_medal`
  44. -- ----------------------------
  45. DROP TABLE IF EXISTS `user_2_medal`;
  46. CREATE TABLE `user_2_medal` (
  47. `id` bigint(20) NOT NULL AUTO_INCREMENT,
  48. `user_id` bigint(20) NOT NULL,
  49. `medal_id` bigint(20) NOT NULL,
  50. `create_time` datetime DEFAULT NULL,
  51. PRIMARY KEY (`id`)
  52. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  53. -- ----------------------------
  54. -- Table structure for `user_integral`
  55. -- ----------------------------
  56. DROP TABLE IF EXISTS `user_integral`;
  57. CREATE TABLE `user_integral` (
  58. `id` bigint(20) NOT NULL AUTO_INCREMENT,
  59. `user_id` bigint(20) NOT NULL,
  60. `total` bigint(20) DEFAULT NULL,
  61. `enabled` bit(1) NOT NULL,
  62. `create_time` datetime NOT NULL,
  63. PRIMARY KEY (`id`)
  64. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  65. SET FOREIGN_KEY_CHECKS = 1;