

InterviewSolution
Saved Bookmarks
1. |
Which of the following is illegal?(a) SELECT SYSDATE – SYSDATE FROM DUAL;(b) SELECT SYSDATE – (SYSDATE – 2) FROM DUAL;(c) SELECT SYSDATE – (SYSDATE + 2) FROM DUAL;(d) None of the MentionedThe question was asked in my homework.The above asked question is from Structured Query Language in section SQL Basics of Oracle |
Answer» <html><body><p>Right answer is (d) None of the Mentioned<br/><br/>The <a href="https://interviewquestions.tuteehub.com/tag/best-390038" style="font-weight:bold;" target="_blank" title="Click to know more about BEST">BEST</a> explanation: SELECT SYSDATE – SYSDATE FROM DUAL; outputs <a href="https://interviewquestions.tuteehub.com/tag/0-251616" style="font-weight:bold;" target="_blank" title="Click to know more about 0">0</a> SELECT SYSDATE – (SYSDATE – <a href="https://interviewquestions.tuteehub.com/tag/2-283658" style="font-weight:bold;" target="_blank" title="Click to know more about 2">2</a>) FROM DUAL; outputs 2<br/><br/>SELECT SYSDATE – (SYSDATE + 2) FROM DUAL; outputs -2.</p></body></html> | |