一、原题
二、题目翻译
三、题目解析
The ORDERS TABLE belongs to the user OE. OE has granted the SELECT privilege on the
ORDERS table to the user HR.
Which statement would create a synonym ORD so that HR can execute the following query
successfully?
SELECT * FROM ord;
A. CREATE SYNONYM ord FOR orders; This command is issued by OE.
B. CREATE PUBLIC SYNONYM ord FOR orders; This command is issued by OE.
C. CREATE SYNONYM ord FOR oe.orders; This command is issued by the database
administrator.
D. CREATE PUBLIC SYNONYM ord FOR oe.orders; This command is issued by the database
administrator.
答案: D
ORDERS table to the user HR.
Which statement would create a synonym ORD so that HR can execute the following query
successfully?
SELECT * FROM ord;
A. CREATE SYNONYM ord FOR orders; This command is issued by OE.
B. CREATE PUBLIC SYNONYM ord FOR orders; This command is issued by OE.
C. CREATE SYNONYM ord FOR oe.orders; This command is issued by the database
administrator.
D. CREATE PUBLIC SYNONYM ord FOR oe.orders; This command is issued by the database
administrator.
答案: D
二、题目翻译
ORDERS表是OE用户的,OE用户授予了SELECT权限给HR。
下面哪句创建同义词ORD的语句后,HR用户能执行下面的查询?
SELECT * FROM ord;
A.CREATE SYNONYM ord FOR orders; 在OE用户下执行这个命令。
B.CREATE PUBLIC SYNONYM ord FOR orders;在OE用户下执行这个命令。
C.CREATE SYNONYM ord FOR oe.orders;数据库管理员执行这个命令。
D.CREATE PUBLIC SYNONYM ord FOR oe.orders;数据库管理员执行这个命令。
下面哪句创建同义词ORD的语句后,HR用户能执行下面的查询?
SELECT * FROM ord;
A.CREATE SYNONYM ord FOR orders; 在OE用户下执行这个命令。
B.CREATE PUBLIC SYNONYM ord FOR orders;在OE用户下执行这个命令。
C.CREATE SYNONYM ord FOR oe.orders;数据库管理员执行这个命令。
D.CREATE PUBLIC SYNONYM ord FOR oe.orders;数据库管理员执行这个命令。
三、题目解析
A选项不正确,这个命令执行后,HR用户可以使用SELECT * FROM oe.ord;查询。
B选项不正确,CREATE PUBLIC SYNONYM执行这个命令需要有权限。
C选项不正确,同A。
D选项正确,创建公共同义词后,其它用户查询不再需要带用户名。
B选项不正确,CREATE PUBLIC SYNONYM执行这个命令需要有权限。
C选项不正确,同A。
D选项正确,创建公共同义词后,其它用户查询不再需要带用户名。