为表TEST中ID列添加主键约束的语法是()
第1题:
Examine the data in the EMPLOYEES table.On the EMPLOYEES table, EMPLOYEE_ID is the primary key. MGR_ID is the ID of managers and refers to the EMPLOYEE_ID. The JOB_ID column is a NOT NULL column.Evaluate this DELETE statement:Why does the DELETE statement fail when you execute it?()
A. There is no row with dept_id 90 in the EMPLOYEES table.
B. You cannot delete the JOB_ID column because it is a NOT NULL column.
C. You cannot specify column names in the DELETE clause of the DELETE statement.
D. You cannot delete the EMPLOYEE_ID column because it is the primary key of the table.
第2题:
您在公司的数据库中成功创建了名为SALARY的表。您现在要通过向引用EMPLOYEES表的匹配列的SALARY表添加FOREIGNKEY约束条件来建立EMPLOYEES表与SALARY表之间的父/子关系。尚未向SALARY表添加任何数据。应执行以下哪条语句()
第3题:
You executed the following code: SQL> CREATE TABLE COUNTRY (COUNTRY_ID CHAR(2) CONSTRAINT COUNTRY_ID_nn NOT NULL, COUNTRY_NAME VARCHAR2(20), CURRENCY_NAME VARCHAR2(20), CONSTRAINT COUNTRY_ID_PK PRIMARY KEY (COUNTRY_ID)) ORGANIZATION INDEX; In which tablespace will the mapping table be created?()
第4题:
您的主管让您修改ORDERS表中的AMOUNT列。他要求将该列配置为接受默认值250。该表包含您需要保留的数据。应执行以下哪条语句来完成此任务()
第5题:
DEPARTMENT 表包含以下列: DEPT_ID NUMBER, Primary Key DEPT_ABBR VARCHAR2(4) DEPT_NAME VARCHAR2(30) MGR_ID NUMBER EMPLOYEE 表包含以下列: EMPLOYEE_ID NUMBER EMP_LNAME VARCHAR2(25) EMP_FNAME VARCHAR2(25) DEPT_ID NUMBER JOB_ID NUMBER MGR_ID NUMBER SALARY NUMBER(9,2) HIRE_DATE DATE 请评估以下语句: ALTER TABLE employee ADD CONSTRAINT REFERENTIAL (mgr_id) TO department(mgr_id); 是以下哪个说法()
第6题:
You need to modify the STUDENTS table to add a primary key on the STUDENT_ID column. The table is currently empty.Which statement accomplishes this task?()
第7题:
Which statement explicitly names a constraint?()
第8题:
6
7
8
9
第9题:
ALTER TABLE student_grades ADD FOREIGN KEY (student_id) REFERENCES students(student_id);
ALTER TABLE student_grades ADD CONSTRAINT NAME = student_id_fk FOREIGN KEY (student_id) REFERENCES students(student_id);
ALTER TABLE student_grades ADD CONSTRAINT student_id_fk FOREIGN KEY (student_id) REFERENCES students(student_id);
ALTER TABLE student grades ADD NAMED CONSTRAINT student_id_fk FOREIGN KEY (student_id) REFERENCES students(student_id);
ALTER TABLE student grades ADD NAME student_id_fk FOREIGN KEY (student_id) REFERENCES students(student_id);
第10题:
The PRIMARY KEY is created along with a new index.
The PRIMARY KEY is created and it would use an existing unique index.
The PRIMARY KEY would be created in a disabled state because it is using an existing index.
The statement produces an error because the USING clause is permitted only in the CREATE TABLE command.
第11题:
ALTER TABLE students ADD PRIMARY KEY student_id;
ALTER TABLE students ADD CONSTRAINT PRIMARY KEY (student _ id);
ALTER TABLE students ADD CONSTRAINT stud _ id _pk PRIMARY KEY (student _ id);
ALTER TABLE students MODIFY CONSTRAINT stud _ id _pk PRIMARY KEY (student _ id);
第12题:
ALTER TABLE雇员MODIFY COLUMN dept_id_fk FOREIGN KEY(部门标识)REFERENCES部门(部门标识)
ALTER TABLE雇员ADD CONSTRAINT dept_id_fk FOREIGNKEY(部门标识)REFERENCES部门(部门标识)
ALTER TABLE雇员ADD FOREIGN KEY CONSTRAINT dept_id_fk ON(部门标识)REFERENCES部门(部门标识)
ALTER TABLE雇员ADD FOREIGN KEY 部门(部门标识)REFERENCES(部门标识)
第13题:
评估以下语句: ALTER TABLE employees ADD CONSTRAINT employee_id PRIMARY KEY; 该语句将返回以下哪种结果()
第14题:
要向雇员表中的部门标识列添加FOREIGNKEY约束条件以引用部门表中的标识列,应该使用哪个语句()
第15题:
数据库中的中的PROFITS表中PRODUCT_NAME与SALE_PERIOD列建立主键。下列哪个语句无法定义这个主键?()
第16题:
评估此CREATE TABLE语句的执行结果: CREATE TABLE part( part_id NUMBER, part_name VARCHAR2(25), manufacturer_id NUMBER(9), retail_price NUMBER(7,2) NOT NULL, CONSTRAINT part_id_pk PRIMARY KEY(part_id), CONSTRAINT cost_nn NOT NULL(cost), CONSTRAINT FOREIGN KEY (manufacturer_id) REFERENCES manufacturer(id)); 哪一行会导致产生错误()
第17题:
You executed the following code: SQL> CERATE TABLE COUNTRY (COUNTRY_ID CHAR(2) CONSTRAINT COUNTRY_ID_nn NOT NULL, COUNTRY_NAME VARCHAR2(20), CURRENCY_NAME VARCHAR2(20), CONSTRAINT COUNTRY_ID_PK PRIMARY KEY (COUNTRY_ID)) ORGANIZATION INDEX; Which types of tables will be created automatically?()
第18题:
You need to modify the STUDENTS table to add a primary key on the STUDENT_ID column. The table is currently empty. Which statement accomplishes this task?()
第19题:
CREATE TABLE test(t_idINT,t_nmae CHAR(10))后,增加t_sex字段,以下语句正确的是()。
第20题:
ALTER TABLE salary ADD CONSTRAINT fk_employee_id_01 FOREIGN KEY(employee_id)REFERENCES employees(employee_id)
ALTER TABLE salary ADD CONSTRAINT fk_employee_id_ FOREIGN KEY BETWEEN salary(employee_id)AND employees(employee_id)
ALTER TABLE salary FOREIGN KEY CONSTRAINT fk_employee_id_REFERENCES employees(employee_id)
ALTER TABLE salary ADD CONSTRAINT fk_employee_id_FOREIGN KEY salary(employee_id)=employees(employee_id)
第21题:
ALTER TABLE students ADD PRIMARY KEY _ id;
ALTER TABLE students ADD CONSTRAINT PRIMARY KEY (student_id);
ALTER TABLE students ADD CONSTRAINT stud_id_pk PRIMARY KEY student_id;
ALTER TABLE students ADD CONSTRAINT stud_id_pk PRIMARY KEY (student_id);
ALTER TABLE students MODIFY CONSTRAINT stud_id_pk PRIMARY KEY (student_id);
第22题:
将返回语法错误
将向EMPLOYEES表添加约束条件
将改写EMPLOYEES表的一个现有约束条件
将启用EMPLOYEES表的一个现有约束条件
第23题:
ALTER TABLE students ADD PRIMARY KEY student_id;
ALTER TABLE students ADD CONSTRAINT PRIMARY KEY (student_id);
ALTER TABLE students ADD CONSTRAINT stud_id_pk PRIMARY KEY student_id;
ALTER TABLE students ADD CONSTRAINT stud_id_pk PRIMARY KEY (student_id);
ALTER TABLE students MODIFY CONSTRAINT stud_id_pk PRIMARY KEY (student_id);