| 发表于:2008-01-12 23:07:44 楼主 |
请写出在class 表中查找满足如下条件的记录的sql语句: 1。返回字段c_name,c_stu 2.返回记录数:前5条 3。查询条件:c_stu值大于30,并且c_type值为真,并且c_type字段值中有“二班”两个字 4。查询结果按c_stu正排序,按c_type倒排序(注:在正排序时请不要省略关键字) 这是一个教程上的题目,答案不对就不能进入下一题,请高手下载附件调试一下,救救我吧!!! 不行啊,我改成这样还是不行 select top 5 c_name,c_stufrom classwhere c_stu > 30 and c_type is not null and c_name like '%二班%' order by c_stu asc,c_type desc |
|
|
|
|