3.5. Review Questions

  1. What is another way to write the following SQL statement by using another function?

    select empno || lpad(initcap(ename),
    40-length(empno),'.')
    "Employee Directory" from emp;

  2. Which function would you use to perform an explicit conversion from a number to a string?

  3. How can you rewrite the function call NUMTOYMINTERVAL(17, 'year') using the function TO_YMINTERVAL?

  4. What is the result of a number added to a NULL value?

  5. What is the result of formatting the number −232.6 using the format mask '9999.99S'?

  6. Rank the following operators or conditionals based on priority, from highest to lowest: *, OR, ||, >=

  7. The DUAL table has how many rows and how many columns?

  8. True or false: Strings and numbers can be concatenated.

  9. Write a SELECT statement with a built-in function or functions that will format the string 'Queen' with the '!' character padded for a total of 20 characters on the left side and with the '?' character padded for a total of 30 characters on the right. (Hint: Use nested functions.)

  10. What functionality does the Oracle TIMESTAMP datatype have over the DATE datatype?

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset