|
|
Authorized user can see question and answers. Please log in or sign up. 
|
#94. The PLAYER table contains these columns: ID NUMBER(9)
NAME VARCHAR(2)
MANAGER ID NUMBER(9) In this instance, managers are players and you need to display a list of players. Evaluate these two SQL statements: SELECT p.name, m.name FROMplayer p, player m WHEREm.id = p.manager_id; SELECT p.name, m.name FROMplayer p, player m WHEREm manager_id = p.id;
How will the results differ?
Show comments for this question (0)
Add comments
Link to this question
|
|
#96. Examine the table structures: EMP Table Name Null Type
EMPNO NOT NULL NUMBER(4)
NAME VARCHAR2(10)
JOB VARCHAR2(9)
MGR NUMBER(4)
HIREDATE DATE
SALARY NUMBER(7,2)
COMM NUMBER(7,2)
DEPTNO NOT NULL NUMBER(2) TAX Table Name Null Type
TAXGRADE NUMBER
LOWSAL NUMBER
HIGHSAL NUMBER You want to create a report that displays the employee details along with the tax category of each employee. The tax category is determined by comparing the salary of the employee from the EMP table to the lower and upper salary values in the TM table. Which SELECT statement produces the required results?
Show comments for this question (0)
Add comments
Link to this question
|
|
#98. Examine the structure of the STUDENT table: Name Null Type
STUD ID NOT NULL NUMBER(3)
NAME VARCHAR2(25)
ADDRESS VARCHAR2(5O)
GRADUATION DATE Currently, the table is empty. You have decided that NULL values should not be allowed for NAME column. Which statement restricts NULL values from being entered into the column?
Show comments for this question (0)
Add comments
Link to this question
|
|
#99. The structure of the DEPT table is as follows: Name Null Type
DEPTNO NOT NULL NUMBER(2)
DNAME VARCHAR2(14)
LOC VARCHAR2(13) Examine the declaration section: DECLARE TYPE dept_record_type IS RECORD (dno NUMBER. name VARCHAR2(20)); dept_rec dept_record_type;
How do you retrieve an entire row of the DEPT table using the DEPT_REC variable?
Show comments for this question (0)
Add comments
Link to this question
|
|
#100. Examine the code: DECLARE CURSOR emp_cursor IS SELECT ename, deptno FROM emp; emp_rec emp_cursor%ROWTYPE; BEGIN OPEN emp_cursor; LOOP FETCH emp_cursor INTO emp_rec; EXIT WHEN emp_cursor%NOTFOUND; INSERT INTO temp_emp(name, dno) VALUES (emp_recename, emp_rec.deptno); END LOOP; CLOSE emp_cursor; END;
Using a cursor FOP loop, which PLJSQL block is equivalent to the above code?
Show comments for this question (0)
Add comments
Link to this question
|
|
|
|
gen. 0.272
|
Server date 10:10 22-11-2008
|
Developed by Zip © 2006
|
|
 |
|
|