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
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?
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
**17000.00
Why **17000.00?????
If the question is correctly written then it will return an error statement. There are missing single quotas. For example this works:
select lpad(17000,10,’*’) from dual;
LPAD(17000,10,’*’)
——————
*****17000
E is the answer.
Yes
The same opinion.
The error appears in “SELECT LPAD(salary,10,*)”. * (asterisk) should be enclosed ‘*’.
E is the answer!
ORA-00936
missing apostrophes