• 2021-04-14 问题

    语句 SELECT * FROM StInfo WHERE ClName = (SELECT ClName FROM StInfo WHERE StName='金萍') 是查询和金萍同班的同学的信息

    语句 SELECT * FROM StInfo WHERE ClName = (SELECT ClName FROM StInfo WHERE StName='金萍') 是查询和金萍同班的同学的信息

  • 2021-04-14 问题

    假定学生表为StInfo(Stid,Stname,Stsex,ClName),其中Stid为学号,Stname为姓名,Stsex为性别,ClName为班级名称。以下SQL语句是用于查询至少有两名男生的班级。但语句不完整,应该选择填入语句最后。 SELECT ClName AS 班级名称 FROM StInfo WHERE Stsex ='男'

    假定学生表为StInfo(Stid,Stname,Stsex,ClName),其中Stid为学号,Stname为姓名,Stsex为性别,ClName为班级名称。以下SQL语句是用于查询至少有两名男生的班级。但语句不完整,应该选择填入语句最后。 SELECT ClName AS 班级名称 FROM StInfo WHERE Stsex ='男'

  • 2022-06-07 问题

    查询所有目前年龄不到18岁的学生的姓名、所在班级及年龄,正确的命令是( )。 A: SELECT StName, ClName,YEAR(GETDATE())-YEAR(birthdate) age FROM StInfo WHERE age<18 B: SELECT StName,ClName, YEAR(GETDATE())-YEAR(birthdate) FROM StInfo WHERE YEAR(birthdate)<18 C: SELECT StName, ClName, YEAR(GETDATE())-YEAR(birthdate) ageFROM StInfo WHERE YEAR(GETDATE())-YEAR(birthdate)<18 D: SELECT StName,ClName, YEAR(date())-YEAR(birthdate) FROM StInfo WHERE age<18

    查询所有目前年龄不到18岁的学生的姓名、所在班级及年龄,正确的命令是( )。 A: SELECT StName, ClName,YEAR(GETDATE())-YEAR(birthdate) age FROM StInfo WHERE age<18 B: SELECT StName,ClName, YEAR(GETDATE())-YEAR(birthdate) FROM StInfo WHERE YEAR(birthdate)<18 C: SELECT StName, ClName, YEAR(GETDATE())-YEAR(birthdate) ageFROM StInfo WHERE YEAR(GETDATE())-YEAR(birthdate)<18 D: SELECT StName,ClName, YEAR(date())-YEAR(birthdate) FROM StInfo WHERE age<18

  • 1