Evaluate the SQL statement: SELECT LPAD(salary,10,*) FROM EM

题目
单选题
Evaluate the SQL statement: SELECT LPAD(salary,10,*) FROM EMP WHERE EMP_ID = 1001; If the employee with the EMP_ID 1001 has a salary of 17000, what is displayed?()
A

17000.00

B

17000*****

C

****170.00

D

**17000.00

E

an error statement

如果没有搜索结果或未解决您的问题,请直接 联系老师 获取答案。
相似问题和答案

第1题:

Exhibit:Examine the data in the EMPLOYEES table.Examine the subquery:SELECT last_nameFROM employeesWHERE salary IN (SELECT MAX(salary)FROM employeesGROUP BY department_id);Which statement is true?()

A. The SELECT statement is syntactically accurate.

B. The SELECT statement does not work because there is no HAVING clause.

C. The SELECT statement does not work because the column specified in the GROUP BY clause is not in the SELECT list.

D. The SELECT statement does not work because the GROUP BY clause should be in the main query and not in the subquery.


参考答案:A

第2题:

Click the Exhibit button and examine the data from the ORDERS and CUSTOMERS tables.Evaluate the SQL statement:SELECT *FROM ordersWHERE cust_id = (SELECT cust_idFROM customersWHERE cust_name = ‘Smith‘);What is the result when the query is executed?()

A.A

B.B

C.C

D.D

E.E


参考答案:A

第3题:

Evaluate this SQL statement:SELECT ename, sal, 12* sal+100 FROM emp;The SAL column stores the monthly salary of the employee. Which change must be made to the abovesyntax to calculate the annual compensation as "monthly salary plus a monthly bonus of $100, multiplied by 12"? ()

A. No change is required to achieve the desired results.

B. SELECT ename, sal, 12* (sal+100) FROM emp;

C. SELECT ename, sal, (12* sal)+100 FROM emp;

D. SELECT ename, sal +100,*12 FROM emp;


参考答案:B

第4题:

The EMPLOYEES table contains these columns: LAST_NAME VARCHAR2 (25) SALARY NUMBER (6,2) COMMISSION_PCT NUMBER (6) You need to write a query that will produce these results: 1. Display the salary multiplied by the commission_pct. 2. Exclude employees with a zero commission_pct. 3. Display a zero for employees with a null commission value. Evaluate the SQL statement: SELECT LAST_NAME, SALARY*COMMISSION_PCT FROM EMPLOYEES WHERE COMMISSION_PCT IS NOT NULL; What does the statement provide? ()

  • A、All of the desired results
  • B、Two of the desired results
  • C、One of the desired results
  • D、An error statement

正确答案:C

第5题:

Evaluate the SQL statement: SELECT LPAD(salary,10,*) FROM EMP WHERE EMP_ID = 1001; If the employee with the EMP_ID 1001 has a salary of 17000, what is displayed?()

  • A、17000.00
  • B、17000*****
  • C、****170.00
  • D、**17000.00
  • E、an error statement

正确答案:E

第6题:

Evaluate the SQL statement:What is the result of the statement?()

A. The statement produces an error at line 1.

B. The statement produces an error at line 3.

C. The statement produces an error at line 6.

D. The statement returns the employee name, salary, department ID, and maximum salary earned in the department of the employee for all departments that pay less salary then the maximum salary paid in the company.

E. The statement returns the employee name, salary, department ID, and maximum salary earned in the department of the employee for all employees who earn less than the maximum salary in their department.


参考答案:E

第7题:

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

正确答案:B

第8题:

Evaluate the SQL statement:SELECT LPAD (salary,10,*)FROM EMPWHERE EMP _ ID = 1001;If the employee with the EMP_ID 1001 has a salary of 17000, what is displayed?()

A. 17000.00

B. 17000*****

C. ****170.00

D. **17000.00

E. an error statement


参考答案:D

第9题:

The EMPLOYEE tables has these columns: LAST_NAME VARCHAR2(35) SALARY NUMBER(8,2) COMMISSION_PCT NUMBER(5,2) You want to display the name and annual salary multiplied by the commission_pct for all employees. For records that have a NULL commission_pct, a zero must be displayed against the calculated column. Which SQL statement displays the desired results?()

  • A、SELECT last_name, (salary * 12) * commission_pct FROM EMPLOYEES;
  • B、SELECT last_name, (salary * 12) * IFNULL(commission_pct, 0) FROM EMPLOYEES;
  • C、SELECT last_name, (salary * 12) * NVL2(commission_pct, 0) FROM EMPLOYEES;
  • D、SELECT last_name, (salary * 12) * NVL(commission_pct, 0) FROM EMPLOYEES;

正确答案:D

第10题:

From SQL*Plus, you issue this SELECT statement: SELECT* FROM order; You use this statement to retrieve data from a data table for ().

  • A、Updating
  • B、Viewing
  • C、Deleting
  • D、Inserting
  • E、Truncating

正确答案:B,D

更多相关问题