AllExam Dumps

DUMPS, FREE DUMPS, VCP5 DUMPS| VMWARE DUMPS, VCP DUMPS, VCP4 DUMPS, VCAP DUMPS, VCDX DUMPS, CISCO DUMPS, CCNA, CCNA DUMPS, CCNP DUMPS, CCIE DUMPS, ITIL, EXIN DUMPS,


READ Free Dumps For Oracle- 1z0-007





Question ID 7913

Examine the structures of the EMPLOYEES and TAX tables. EMPLOYEES EMPLOYEE_ID NUMBER NOT NULL, Primary Key

EMP_NAME VARCHAR2 (30) JOB_ID VARCHAR2 (20)

SALARY NUMBER References MGR_ID NUMBER EMPLOYEE_ID column DEPARTMENT_ID NUMBER Foreign key to DEPARTMENT _ID column of the DEPARTMENT table

TAX

MIN_SALARY NUMBER

MAX_SALARY NUMBER TAX_PERCENT NUMBER Percentage tax for given salary range

You need to find the percentage tax applicable for each employee. Which SQL statement would you use?

Option A

SELECT employee_id, salary, tax_percent FROM employees e, tax t WHERE e.salary BETWEEN t.min _ salary AND t.max_salary

Option B

SELECT employee_id, salary, tax_percent FROM employees e, tax t WHERE e.salary > t.min_salary, tax_percent

Option C

SELECT employee_id, salary, tax_percent FROM employees e, tax t WHERE MIN(e.salary) = t.min_salary AND MAX(e.salary) = t.max_salary

Option D

You cannot find the information because there is no common column between the two tables. 

Correct Answer A
Explanation Explanation/Reference: Explanation: You can find the percentage tax applicable for each employee by using SQL statement in answer A. Incorrect Answers B: Syntax "WHERE e.salary > t.min_salary, tax_percent" is incorrect. C: Functions, like MIN() and MAX(), cannot be used in the WHERE clause. D: The SQL statement from the answer A will provide requested information. OCP Introduction to Oracle 9i: SQL Exam Guide, Jason Couchman, p. 98-103 Chapter 3: Advanced Data Selection in Oracle


Question ID 7914

Mary has a view called EMP_DEPT_LOC_VU that was created based on the EMPLOYEES, DEPARTMENTS, and LOCATIONS tables. She granted SELECT privilege to Scott on this view. Which option enables Scott to eliminate the need to qualify the view with the name MARY .EMP_DEP_LOC_VU each time the view is referenced?

Option A

Scott can create a synonym for the EMP_DEPT_LOC_VU bus using the command: CREATE PRIVATE SYNONYM EDL_VU FOR mary.EMP DEPT_LOC_VU; then he can prefix the columns with this synonymn.

Option B

Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command: CREATE SYNONYM EDL_VU FOR mary.EMP_DEPT_LOC_VU; then he can prefix the columns with this synonym.

Option C

Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command: CREATE LOCAL SYNONYM EDL_VU FOR mary.EMP DEPT_LOC_VU; then he can prefix the columns with this synonym.

Option D

Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command: CREATE SYNONYM EDL_VU ON mary(EMP_DEPT_LOC_VU); then he can prefix the columns with this synonym.

Option E

Scott cannot create a synonym because synonyms can be created only for tables.

Option F

Scott cannot create any synonym for Mary's view. Mary should create a private synonym for the view and grant SELECT privilege on that synonym to Scott.

Correct Answer B
Explanation Explanation/Reference: Explanation: Correct syntax to create a local synonym is CREATE SYNONYM synonym_name. With PUBLIC keyword you can create public synonym. Incorrect Answers A: There is no PRIVATE keyword for the CREATE SYNONYM command. C: There is no LOCAL keyword for the CREATE SYNONYM command. D: This SQL statement shows incorrect syntax to create a synonym. E: Synonyms can be created not only for tables but for other objects also. F: Scott can create synonym for Mary's view because she granted SELECT privilege to Scott on this view. OCP Introduction to Oracle 9i: SQL Exam Guide, Jason Couchman, p. 331-335 Chapter 7: Creating Other Database Objects in Oracle

Send email to admin@getfreedumps for new dumps request!!!