How Oracle can perform simple plus and minus operations on time

Source: Internet
Author: User

We need to set the time interval when we use the Dbms_job package for timed job, so we need to know the basic method of adding and reducing time.

Sql> AlterSessionSetNls_date_format='YYYY-MM-DD Hh24:mi:ss'; The session has changed. SQL> SelectSysdate, Sysdate+1/ -, Sysdate+1/1440, Sysdate+ 1/86400  fromdual;--one hour, one minute, one second sysdate sysdate+1/ -Sysdate+1/1440Sysdate+1/86400------------------- ------------------- ------------------- ------------------- the- -- - xx: -: the  the- -- -  on: -: the  the- -- - xx: -: the  the- -- - xx: -: +SQL> SelectSysdate,sysdate+  -/( -* -* -) fromdual;--Add a minute sysdate sysdate+ -/( -* -*6)------------------- ------------------- the- -- - xx: -: $  the- -- - xx: -: $

The basic usage of the Dbms_job package is referenced below.

Http://www.cnblogs.com/princessd8251/articles/3829430.html

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.