Which of the following is a valid SQL statement?SELECT UPPER(Hello) FROM dual; SELECT SYSDATE;   SELECT TO_CHAR(SYSDATE, 'Month DD, YYYY') FROM dual; all of the above none of the above Which...


Which of the following is a valid SQL statement?SELECT UPPER(Hello) FROM dual;



  • SELECT SYSDATE;


  • SELECT TO_CHAR(SYSDATE, 'Month DD, YYYY')

  • FROM dual;

  • all of the above

  • none of the above



  • Which of the following functions can be used to extract a portion of a character string?

  • EXTRACT

  • TRUNC

  • SUBSTR

  • INITCAP



  • Which of the following determines how long ago orders that haven’t shipped were received?

  • SELECT order#, shipdate-orderdate delay FROM orders;

  • SELECT order#, SYSDATE – orderdate FROM orders WHERE shipdate IS NULL;

  • SELECT order#, NVL(shipdate, 0) FROM orders WHERE orderdate is NULL;

  • SELECT order#, NULL(shipdate) FROM orders;



  • Which of the following SQL statements produces “Hello World” as the output?

  • SELECT "Hello World" FROM dual;

  • SELECT INITCAP('HELLO WORLD') FROM dual;

  • SELECT LOWER('HELLO WORLD') FROM dual;

  • both a and b

  • none of the above



  • Which of the following functions can be used to substitute a value for a NULL value?

  • NVL

  • TRUNC

  • NVL2

  • SUBSTR

  • both a and d

  • both a and c



  • Which of the following is not a valid format argument for displaying the current time?

  • 'HH:MM:SS'

  • 'HH24:SS'

  • 'HH12:MI:SS'

  • All of the above are valid.



  • Which of the following lists only the last four digits of the contact person’s phone number at American Publishing?

  • SELECT EXTRACT(phone, -4, 1) FROM publisher WHERE name ¼ 'AMERICAN PUBLISHING';

  • SELECT SUBSTR(phone, -4, 1) FROM publisher WHERE name = 'AMERICAN PUBLISHING';

  • SELECT EXTRACT(phone, -1, 4) FROM publisher WHERE name = 'AMERICAN PUBLISHING';

  • SELECT SUBSTR(phone, -4, 4) FROM publisher WHERE name = 'AMERICAN PUBLISHING';



  • Which of the following functions can be used to determine how many months a book has been available?

  • MONTH

  • MON

  • MONTH_BETWEEN

  • none of the above



  •  Which of the following displays the order date for order 1000 as 03/31?

  • SELECT TO_CHAR(orderdate, 'MM/DD') FROM orders WHERE order# = 1000;

  • SELECT TO_CHAR(orderdate, 'Mth/DD') FROM orders WHERE order# = 1000;

  • SELECT TO_CHAR(orderdate, 'MONTH/YY') FROM orders WHERE order# = 1000;

  • both a and b

  • none of the above



  •  Which of the following functions can produce different results, depending on the value of a specified column?

  • NVL

  • DECODE

  • UPPER


SUBSTR



Nov 11, 2021
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here