问题
单项选择题
使用SQL语句将学生表S中年龄(AGE)大于30岁的记录删除,正确的命令是()。
A.DELETE FOR AGE>30
B.DELETE FROM S WHERE AGE>30
C.DELETE S FOR AGE>30
D.DELETE S WHERE AGE>30
答案
参考答案:B
解析:
SQL从表中删除数据的命令格式如下:
DELETE FROM 表名[WHERE 条件]
使用SQL语句将学生表S中年龄(AGE)大于30岁的记录删除,正确的命令是()。
A.DELETE FOR AGE>30
B.DELETE FROM S WHERE AGE>30
C.DELETE S FOR AGE>30
D.DELETE S WHERE AGE>30
参考答案:B
解析:
SQL从表中删除数据的命令格式如下:
DELETE FROM 表名[WHERE 条件]