单项选择题Which are iSQL*Plus commands? ()

A.INSERT
B.UPDATE
C.SELECT
D.DESCRIBE
E.DELETE
F.RENAME


您可能感兴趣的试卷

你可能感兴趣的试题

1.多项选择题

Examine the description of the MARKS table:
STD_ID NUMBER(4)
STUDENT_NAME VARCHAR2(30)
SUBJ1 NUMBER(3)
SUBJ2 NUMBER(3)
SUBJ3 NUMBER(3)
SUBJ1, SUBJ2, and SUBJ3 indicate the marks (grades) obtained by a student in the three subjects. Which two statements are valid? ()

A.SELECT SUM(subj1, subj2, subj3) FROM marks;
B.SELECT SUM(subj1 + subj2 + subj3) FROM marks;
C.SELECT SUM(subj1), SUM(subj2), SUM(subj3) FROM marks;
D.SELECT MAX(subj1, subj2, subj3) FROM marks;
E.SELECT MINIMUM(subj1) FROM marks;
F.SELECT COUNT(std_id) FROM marks WHERE subj1 >= AVG(subj1);

2.单项选择题

Examine the description of the EMPLOYEES table:

Which statement produces the number of different departments that have employees with last name Smith?()

A.SELECT COUNT(*) FROM employees WHERE last_name='Smith';
B.SELECT COUNT(dept_id) FROM employees WHERE last_name='Smith';
C.SELECT DISTINCT(COUNT(dept_id)) FROM employees WHERE last_name='Smith';
D.SELECT COUNT(DISTINCT dept_id) FROM employees WHERE last_name='Smith';
E.SELECT UNIQUE(dept_id) FROM employees WHERE last_name='Smith';

3.单项选择题Which SELECT statement should you use to extract the year from the system date and display it in the format "1998"?()

A.SELECT TO_CHAR(SYSDATE,'yyyy') FROM dual;
B.SELECT TO_DATE(SYSDATE,'yyyy') FROM dual;
C.SELECT DECODE(SUBSTR(SYSDATE, 8), 'YYYY') FROM dual;
D.SELECT DECODE(SUBSTR(SYSDATE, 8), 'year') FROM dual;
E.SELECT TO_CHAR(SUBSTR(SYSDATE, 8,2),'yyyy') FROM dual;

4.单项选择题In which scenario would an index be most useful?()

A.The indexed column is declared as NOT NULL.
B.The indexed columns are used in the FROM clause.
C.The indexed columns are part of an expression.
D.The indexed column contains a wide range of values.

5.单项选择题

Evaluate these two SQL statements:
SELECT last_name, salary , hire_date
FROM EMPLOYEES
ORDER BY salary DESC;
SELECT last_name, salary , hire_date
FROM EMPLOYEESORDER BY 2 DESC;
What is true about them?()

A.The two statements produce identical results.
B.The second statement returns a syntax error.
C.There is no need to specify DESC because the results are sorted in descending order by default.
D.The two statements can be made to produce identical results by adding a column alias for the salary column in the second SQL statement.

6.单项选择题Which SQL statement accepts user input for the columns to be displayed, the table name, and the WHERE condition?()

A.SELECT &1, "&2" FROM &3 WHERE last_name = '&4';
B.SELECT &1, '&2' FROM &3 WHERE '&last_name = '&4'';
C.SELECT &1, &2 FROM &3 WHERE last_name = '&4';
D.SELECT &1, '&2' FROM EMP WHERE last_name = '&4';

7.多项选择题Click the Exhibit button and examine the data in the EMPLOYEES table. Which three subqueries work?()

A.SELECT * FROM employees where salary > (SELECT MIN(salary) FROM employees GROUP BY department_id);
B.SELECT * FROM employees WHERE salary = (SELECT AVG(salary) FROM employees GROUP BY department_id);
C.SELECT distinct department_id FROM employees WHERE salary > ANY (SELECT AVG(salary) FROM employees GROUP BY department_id);
D.SELECT department_id FROM employees WHERE salary > ALL (SELECT AVG(salary) FROM employees GROUP BY department_id);
E.SELECT last_name FROM employees WHERE salary > ANY (SELECT MAX(salary) FROM employees GROUP BY department_id);
F.SELECT department_id FROM employees WHERE salary > ALL (SELECT AVG(salary) FROM employees GROUP BY AVG(SALARY));

8.单项选择题Which SQL statement defines a FOREIGN KEY constraint on the DEPTNO column of the EMP table?()

A.CREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk FOREIGN KEY deptno REFERENCES dept deptno);
B.CREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));
C.CREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk REFERENCES dept (deptno) FOREIGN KEY (deptno));
D.CREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) FOREIGN KEY CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));

9.单项选择题Click the Exhibit button and examine the data in the EMPLOYEES and DEPARTMENTS tables.You want to retrieve all employees, whether or not they have matching departments in the departments table. Which query would you use?()

A.SELECT last_name, department_name FROM employees NATURAL JOIN departments;
B.SELECT last_name, department_name FROM employees JOIN departments ;
C.SELECT last_name, department_name FROM employees e JOIN departments d ON (e.department_id = d.department_id);
D.SELECT last_name, department_name FROM employees e RIGHT OUTER JOIN departments d ON (e.department_id = d.department_id);
E.SELECT last_name, department_name FROM employees FULL JOIN departments ON (e.department_id = d.department_id);
F.SELECT last_name, department_name FROM employees e LEFT OUTER JOIN departments d ON (e.department_id = d.department_id);

10.单项选择题Which SQL statement generates the alias Annual Salary for the calculated column SALARY*12?()

A.SELECT ename, salary*12 'Annual Salary' FROM employees;
B.SELECT ename, salary*12 "Annual Salary" FROM employees;
C.SELECT ename, salary*12 AS Annual Salary FROM employees;
D.SELECT ename, salary*12 AS INITCAP("ANNUAL SALARY") FROM employees

最新试题

Evaluate these two SQL statements: SELECT last_name, salary, hire_dateFROM EMPLOYEES ORDRE BY salary DESC; SELECT last_name, salary, hire_dateFROM EMPOLYEES ORDER BY 2 DESC; What is true about them? ()

题型:单项选择题

Which object privileges can be granted on a view? ()

题型:单项选择题

Which SQL statement displays the date March 19, 2001 in a format that appears as "Nineteenth of March 2001 12:00:00 AM"? ()

题型:单项选择题

Examine the statement: Create synonym emp for hr. employees; What happens when you issue the statement? ()

题型:单项选择题

What is true regarding subqueries?()

题型:单项选择题

Examine the structure of the EMPLOYEES table: EMPLOYEE_ID NUMBER Primary KeyFIRST_NAME VARCHAR2 (25)LAST_NAME VARCHAR2 (25)HIRE_DATE DATEWhich UPDATE statement is valid? ()

题型:单项选择题

Which three statements about subqueries are true? ()

题型:多项选择题

A SELECT statement can be used to perform these three functions:1. Choose rows from a table.2. Choose columns from a table3. Bring together data that is stored in different tables by creating a link between them. Which set of keywords describes these capabilities? ()

题型:单项选择题

You need to design a student registration database that contains several tables storing academic information.The STUDENTS table stores information about a student. The STUDENT_GRADES table storesinformation about the student's grades. Both of the tables have a column named STUDENT_ID. The STUDENT_ID column in the STUDENTS table is a primary key.You need to create a foreign key on the STUDENT_ID column of the STUDENT_GRADES table thatpoints to the STUDENT_ID column of the STUDENTS table. Which statement creates the foreign key?()

题型:单项选择题

Which one is a system privilege? ()

题型:单项选择题