关于查询中列的别名, 以下()语句是不正确的(选一项)
A: Select name as '姓名' from table
B: Select name as姓名 from table where id =1
C: Sleect name = 姓名 from table
D: Select names姓名 from table
A: Select name as '姓名' from table
B: Select name as姓名 from table where id =1
C: Sleect name = 姓名 from table
D: Select names姓名 from table
举一反三
- 下面哪条语句可以查询姓“张”并且年龄等于20岁的用户,请问用哪条语句? A: Select * From table Where name like "%张%" And intAge=20 B: Select * From table Where name like "张%" And intAge=20 C: Select * From table Where name like "张%" And intAge="20" D: Select * From table Where name="张" And intAge=20
- 已知 student 表有姓名字段 name。若想查询所有姓“王”的学生,并且姓名由三个字符组成,则应使用的SQL 语句是 A: SELECT* FROM student WHERE name LIKE ‘王__’; B: SELECT* FROM student WHERE name LIKE ‘王%_’; C: SELECT* FROM student WHERE name LIKE ‘王%’; D: SELECT* FROM student WHERE name =’王__’;
- 下面哪一个语句,显示没有Email地址的教师姓名() A: Select name from teacher where email=NULL; B: Select name from teacher where email C: Select name from teacher where email is NULL; D: Select name from teacher where emailis not NULL;
- 基于表S创建视图R的SQL语句是【 】 A: CREATE R AS SELECT 学号,姓名 FROM S B: CREATE TABLE R AS SELECT 学号,姓名 FROM S C: CREATE VIEW R AS SELECT 学号,姓名 FROM S D: CREATE R FROM SELECT 学号,姓名 AS S
- 查询student表中id字段值小于5,并且gender字段值为“女”的学生姓名的SQL语句是() A: SELECT name FROM student WHERE id<;5 OR gender='女'; B: SELECT name FROM student WHERE id<;5 AND gender='女'; C: SELECT name FROM student WHERE id<;5 ,gender='女'; D: SELECT name FROM student WHERE id<;5 AND WHERE gender='女';