配置mysql连接,如下图:
填写mysql地址,用户名,密码,如果没有安装驱动,要先安装驱动
测试数据库能否连接成功:
保存配置,保存时,会提示设置密码:
读取数据库表,及根据条件查询修改:
mysql error1241:Operand shou--根据报错来看 ,你下面的一个查询返回了两个值 cou_name as 最优秀课程,sco_score as 成绩--Operand should contain 1 column(s)
(select cou_name as 最优秀课程,sco_score as 成绩 from cou,sco where cou.cou_id=sco.cou_id group by stu_id having sco_score=max(sco_score)),
(select cou_name as 最差课程,sco_score as 成绩 from cou,sco where cou.cou_id=sco.cou_id group by stu_id having sco_score=min(sco_score)),ld contain 1 column(s)
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)