下面选项中,能够更新user表中数据的SQL语句是()
A: update into user set id = 'u001';
B: update user set id = 'u001' and username='jack';
C: update user set username='jack' where id = 1;
D: update into user set id = 'u001', username='jack';
A: update into user set id = 'u001';
B: update user set id = 'u001' and username='jack';
C: update user set username='jack' where id = 1;
D: update into user set id = 'u001', username='jack';
举一反三
- 下列用于更新的SQL语句中,正确的是() A: update<br/>user set id = u001 ; B: update<br/>user(id,username) values('u001','jack'); C: update<br/>user set id='u001',username='jack'; D: update<br/>into user set id = 'u001', username='jack';
- 【多选题】已知user表中存在一个字段id。 下面选项中,能够查询出id编号为u001和u002的用户的SQL语句是 A. select * from user where id = 'u001' and id = 'u002'; B. select * from user where id = 'u001' or id = 'u002'; C. select * from user where
- 下面选项中,用于将表user中字段age值更新为55的SQL语句是 A: ALTER TABLE user set age=55; B: UPDATE user set age=55 where age=55; C: UPDATE user set age=55; D: UPDATE user set age=55 where age<=55;
- 【多选题】下列SQL语句在实际运行时,可能转换的SQL语句为() update user <set> <if test="uname!=null">uname=#{uname}, </if> <if test="usex!=null">usex=#{usex}</if> </set> where uid=#{uid} A. update user set uname=#{uname} where uid=#{uid} B. update user set uname=#{uname}, usex=#{usex} where uid=#{uid} C. update user usex=#{usex} where uid=#{uid} D. update user set uname=#{uname}, usex=#{usex}
- 已知用户表 user 有多列,其中字段 id 没有 NULL 值,字段username有NULL值,选项中,不能获得 user 表的总记录数量的 SQL 语句是 A: SELECT COUNT (*) FROM user ; B: SELECT COUNT ( id ) FROM user ; C: SELECT COUNT ( username ) FROM user ; D: SELECT COUNT ( id ) FROM user WHERE 1=1;