以下为《Mysql题目》的无排版文字预览,完整格式请下载
下载前请仔细阅读文字预览以及下方图片预览。图片预览是什么样的,下载的文档就是什么样的。
Mysql题目
一、选择题(每题2分,共20分)
1、支持主外键,索引及事务的存储引擎为是( )
A.MYISAM
B.INNODB
C.MEMORY
D.CHARACTER
2、创建用户的命令是()
A.join user
B.create user
C.create root
D.mysql user
3、有订单表orders,包含用户信息userid,产品信息productid,以下()语句能够返回至少被订购过两回的productid?()
A.select productid from orders where count(productid)>1
B.select productid from orders where max(productid)>1
C.select productid from orders where having count(productid)>1 group by productid
D.select productid from orders group by productid having count(productid)>1
4、mysql中,备份数据库的命令是( )
A.mysqldump
B.mysql
C.backup
D.copy
5、删除用户的命令是( )
A.drop user
B.delete user
C.drop root
D.truncate user
6、给名字是zhangsan的用户分配对数据库studb中的stuinfo表的查询和插入数据权限的语句是( )
A.grant select,insert on studb.stuinfo for‘zhangsan’@’localhost’
B.grant select,insertonstudb.stuinfo to‘zhangsan’@’localhost’
C.grant‘zhangsan’@’localhost’to select,insert for studb.stuinfo
D.grant‘zhangsan’@’localhost’to studb.stuinfo on select,insert
7、从学生(STUDENT)表中的姓名(NAME)字段查找姓“张”的学生可以使用如下代码:select?*?from?student?where。? ()
A.NAME=’张*’
B.NAME=‘%张%’?
C.NAME?LIKE?‘张%’?
D.NAME?LIKE?‘张*’
8、要快速完全清空一个表,可以使用如下语句:()
A.?TRUNCATE?TABLE
B.?DELETE?TABLE?
C.?DROP?TABLE
D.?CLEAR?TABLE?
9、改表记录的语句关键字是:()
A delete??
B?update?
C?insert??
D?select?
10、修改操作的语句 update?student?set?s_name?=N’王军’?该代码执行后的结果是: ()
A 只把姓名叫王军的记录进行更新?
B 只把字段名s_name?改成 N’王军’
C 表中的所有人姓名都更新为王军?
D 更新语句不完整,不能执行
二、填空题(每题4分,共20分)
1、显示mysql中所有db用_________命令?
2、显示某个数据库中所有表用_________ 内容过长,仅展示头部和尾部部分文字预览,全文请查看图片预览。 T_EXP_OP WHERE AUX_OP_CODE IN ('NEW','UPDATE','DELETE') AND ((OP_CODE IN (176, 162, 171, 131, 136) AND EXP_TYPE IN ('10', '20', '30')) OR(OP_CODE IN (191, 121)AND EXP_TYPE IN ('10', '20')) OR (OP_CODE IN (181,111)AND EXP_TYPE = '10'))) LIMIT 10;
条件:
T_EXP_OP表主键为BIGINT类型的ID字段,存储引擎为InnoDB,无其他索引
[文章尾部最后300字内容到此结束,中间部分内容请查看底下的图片预览]请点击下方选择您需要的文档下载。
以上为《Mysql题目》的无排版文字预览,完整格式请下载
下载前请仔细阅读上面文字预览以及下方图片预览。图片预览是什么样的,下载的文档就是什么样的。