pushsubscribe.sql 1.3 KB

123456789101112131415161718192021222324
  1. CREATE TABLE `wcjtest` (
  2. `id` bigint(20) NOT NULL AUTO_INCREMENT,
  3. `userid` char(24) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '用户id',
  4. `infoid` char(24) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '信息id',
  5. `matchkeys` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '匹配词',
  6. `area` smallint(6) DEFAULT NULL COMMENT '省份',
  7. `city` smallint(6) DEFAULT NULL COMMENT '城市',
  8. `buyerclass` int(11) DEFAULT NULL COMMENT '采购单位行业',
  9. `toptype` int(11) DEFAULT NULL COMMENT '一级信息类型',
  10. `subtype` int(11) DEFAULT NULL COMMENT '二级信息类型',
  11. `date` int(11) NOT NULL COMMENT '推送时间',
  12. `isvisit` tinyint(4) DEFAULT NULL COMMENT '是否访问过',
  13. `isvip` tinyint(4) DEFAULT NULL COMMENT '0-免费用户 1-付费用户',
  14. `type` tinyint(4) DEFAULT NULL COMMENT '0-信息匹配 1-项目匹配',
  15. PRIMARY KEY (`id`,`userid`),
  16. KEY `index_userid` (`userid`) USING BTREE,
  17. KEY `index_date` (`date`) USING BTREE,
  18. KEY `index_city` (`city`) USING BTREE,
  19. KEY `index_toptype` (`toptype`) USING BTREE,
  20. KEY `index_subtype` (`subtype`) USING BTREE,
  21. KEY `index_area` (`area`) USING BTREE
  22. ) ENGINE=InnoDB AUTO_INCREMENT=185010353 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci
  23. PARTITION BY KEY (userid)
  24. PARTITIONS 10 ;