企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
创建表: ``` CREATE TABLE `user` ( `id` int(32) NOT NULL AUTO_INCREMENT, `name` varchar(16) NOT NULL, `kindid` int(32) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; CREATE TABLE `userkind` ( `id` int(32) NOT NULL AUTO_INCREMENT, `kindname` varchar(16) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; INSERT INTO `user` VALUES (1,'小明',1),(2,'小红',1),(3,'涵涵',2); INSERT INTO `userkind` VALUES (1,'普通会员'),(2,'VIP会员'); ``` 搜索 ``` select `user`.`id`,`name`,`kindname` from `user` inner join `userkind` on `user`.`kindid`=`userkind`.`id`; ```