关于sql语句语法的问题
SELECTa.tname,cast(b.attitudeaschar)b.attitude,cast(b.contentaschar)b.content,cast(b....
SELECT a.tname,cast(b.attitude as char) b.attitude,cast(b.content as char) b.content,cast(b.method as char) b.method,cast(b.task_examine as char) b.task_examine,
cast(b.material as char) b.material, FROM teacher a,result b WHERE a.tnum=b.tnum
请问这条sql语句哪里出了问题,数据元素没有问题,主要是语法上的。 展开
cast(b.material as char) b.material, FROM teacher a,result b WHERE a.tnum=b.tnum
请问这条sql语句哪里出了问题,数据元素没有问题,主要是语法上的。 展开
2个回答
展开全部
语句这样试试
SELECT a.tname,cast(b.attitude as char) attitude,cast(b.content as char) content,cast(b.method as char) method,cast(b.task_examine as char) task_examine,
cast(b.material as char) material, FROM teacher a,result b WHERE a.tnum=b.tnum
SELECT a.tname,cast(b.attitude as char) attitude,cast(b.content as char) content,cast(b.method as char) method,cast(b.task_examine as char) task_examine,
cast(b.material as char) material, FROM teacher a,result b WHERE a.tnum=b.tnum
追问
FROM teacher a,result b WHERE a.tnum=b.tnum这一段好像也有错误
追答
你把from 前面的逗号去掉,查询语句的最後一个字段不用加逗号
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询