要查询Goods表中商品中含有“电冰箱”的商品情况,可用( )
A: SELECT * FROM Goods WHERE g_Name LIKE '电冰箱%'
B: SELECT * FROM Goods WHERE g_Name LIKE '电冰箱_'
C: SELECT * FROM Goods WHERE g_Name LIKE '%电冰箱%'
D: SELECT * FROM Goods WHERE g_Name='电冰箱'
A: SELECT * FROM Goods WHERE g_Name LIKE '电冰箱%'
B: SELECT * FROM Goods WHERE g_Name LIKE '电冰箱_'
C: SELECT * FROM Goods WHERE g_Name LIKE '%电冰箱%'
D: SELECT * FROM Goods WHERE g_Name='电冰箱'
举一反三
- 下面正确表示查询goods表中type和name的SQL语句是。 A: select * from goods; B: select type name from goods; C: select type,name from goods; D: select name type from goods;
- 要查询Goods表中的商品名称含有“电冰箱”的商品情况,可以使用()命令 A: select*fromGoodswhereg_Namelike'电冰箱%' B: select*fromGoodswhereg_Namelike'电冰箱_' C: select*fromGoodswhereg_Namelike'%电冰箱%' D: select*fromGoodswhereg_Name='电冰箱'
- 下列哪些SQL语句可以查询出User表中name为张三的记录()。 A: SELECT * FROM User WHERE name = ’张三’ B: SELECT * FROM User WHERE name = ’张三’ LIMIT 0,1 C: SELECT * FROM User WHERE name LIKE ’张三’ D: SELECT * FROM User WHERE name LIKE ’%张三%’
- 若想查询student表中name为空值的记录,则正确的SQL语句是( )。 A: SELECT * FROM student WHERE name = NULL; B: SELECT * FROM student WHERE name like NULL; C: SELECT * FROM student WHERE name = 'NULL'; D: SELECT * FROM student WHERE name is NULL;
- 下面查询语句中哪条查询语句会查询出所有包含"李"的数据? A: select * from student where name limit‘%李%’ B: select * from student where name =‘%李%’ C: select * from student where name like‘%李%’ D: select * from student where name in‘%李%’