47. View the Exhibit and examine the structure of ORD and ORD_ITEMS tables.
composite PRIMARY KEY in the ORD_ITEMS table.
Which two CREATE INDEX statements are valid? (Choose two.)
A. CREATE INDEX ord_idx1
ON ord(ord_no);
B. CREATE INDEX ord_idx2
ON ord_items(ord_no);
C. CREATE INDEX ord_idx3
ON ord_items(item_no);
D. CREATE INDEX ord_idx4
ON ord,ord_items(ord_no, ord_date,qty);
Answer: BC
题目解析:
由于主键会自动创建唯一索引,所以A选项的索引都已经存在,所以会报错。
D选项在两张表上的字段建立组合索引,属于语法错误。