Posted By

bbrumm on 02/22/17


Tagged

sql Oracle


Versions (?)

Oracle NUMTOYMINTERVAL Function


 / Published in: SQL
 

URL: http://www.databasestar.com/oracle-numtoyminterval/

A few examples of the NUMTOYMINTERVAL function.

  1. --NUMTOYMINTERVAL
  2.  
  3.  
  4. --Example 1
  5. SELECT NUMTOYMINTERVAL(15, 'YEAR') AS YMTEST
  6. FROM dual;
  7.  
  8.  
  9. --Example 2
  10. SELECT NUMTOYMINTERVAL(23, 'MONTH') AS YMTEST
  11. FROM dual;
  12.  
  13.  
  14. --Example 3
  15. SELECT NUMTOYMINTERVAL(-4, 'YEAR') AS YMTEST
  16. FROM dual;
  17.  
  18.  
  19. --Example 4
  20. SELECT NUMTOYMINTERVAL(-18, 'MONTH') AS YMTEST
  21. FROM dual;

Report this snippet  

You need to login to post a comment.