|
|
Authorized user can see question and answers. Please log in or sign up. 
|
#171. The PRODUCT table contains these columns: PRODUCT_ID NUMBER NOT NULL
PRODUCT_NAME VARCHAR2(25)
SUPPLIER_ID NUMBER
LIST_PRICE NUMBER(7,2)
COST NUMBER(7,2) You need to increase the list price and cost of all products supplied by Global Imports, Inc. by 5.5 percent. The SUPPLIER_ID for Global Imports, Inc. is 105. Which statement should you use?
Show comments for this question (1)
Add comments
Link to this question
|
|
#173. Examine the structures of the EVENT and NEW_EVENT tables. You execute this MERGE statement: MERGE INTO EVENT e USING (SELECT * FROM new_event WHERE event_type_id = 4) n ON (e.event_id = n.event_id) WHEN MATCHED THEN UPDATE SET e.event_type_id = n.event_type_id, e.start_dt = n.start_dt WHEN NOT MATCHED THEN INSERT (event_id, event_name, event_type_id) VALUES(n.event_id, n.event_name, n.event_type_id);
This MERGE statement generates an error. Which statement describes the cause of the error?
Show comments for this question (1)
Add comments
Link to this question
|
|
#175. The STUDENT table contains these columns: STU_ID NUMBER(9) NOT NULL
LAST_NAME VARCHAR2(30) NOT NULL
FIRST_NAME VARCHAR2(25) NOT NULL
DOB DATE
STU_TYPE_ID VARCHAR2(1) NOT NULL
ENROLL_DATE DATE You create another table, named PT_STUDENT, with an identical structure. You want to insert all part-time students, who have a STU_TYPE_ID value of "P", into the new table. You execute this INSERT statement: INSERT INTO pt_student (SELECT stu_id, last_name, first_name, dob, SYSDATE FROM student WHERE UPPER(stu_type_id) = 'P');
What is the result of executing this INSERT statement?
Show comments for this question (1)
Add comments
Link to this question
|
|
#176. Examine the structures of the AR_TRX and AR_TRX_HY tables. You are loading historical accounts receivable data from the AR_TRX table into the AR_TRX_HY table. During the load, you want to transform the data so that the GRAND_TOTAL column of the AR_TRX_HY table is equal to the sum of the EXT_AMT and TAX_AMT columns in the AR_TRX table. You want to set LOAD_DATE to the current date. If the record already exists in the target table, all values, except TRX_ID and TRX_TYPE, should be refreshed with the most recent data. Which MERGE statement should you execute?
Show comments for this question (1)
Add comments
Link to this question
|
|
#177. EMPLOYEES and DEPARTMENTS data: On the EMPLOYEES table, EMPLOYEE_ID is the primary key. MGR_ID is the ID managers and refers to the EMPLOYEE_ID. On the DEPARTMENTS table DEPARTMENT_ID is the primary key. Evaluate this UPDATE statement. UPDATE employees SET mgr_id = (SELECT mgr_id FROM employees WHERE dept_id= (SELECT department_id FROM departments WHERE department_name = 'Administration')), Salary = (SELECT salary FROM employees WHERE emp_name = 'Smith') WHERE job_id = 'IT_ADMIN';
What happens when the statement is executed?
Show comments for this question (0)
Add comments
Link to this question
|
|
|
|
gen. 0.115
|
Server date 03:33 08-01-2009
|
Developed by Zip © 2006
|
|
 |
|
|