Get the App
SLTechnology News&Howtos  ›  Database  › 

How does oralce calculate the time difference

Shulou Source: shulou.com Published: 2022-05-31 21:18:21 10月03日 Update

This article mainly introduces oralce how to calculate the time difference, the article is very detailed, has a certain reference value, interested friends must read it!

Realization of calculating time difference in oralce

Query the number of milliseconds between the system time and the given time

Select ceil ((sysdate-To_date ('2017-03-23 00 yyyy-mm-dd hh34-mi-ss')) * 24 * 60 * 60 * 1000) FROM DUAL

Calculate the difference in seconds between the dcur_state_start_date (timestamp type) field values of the first data in the account table

Select ceil ((sysdate-TO_DATE (TO_CHAR (a. Dcurries statehands startmate HH24:MI:SS'), 'YYYY-MM-DD HH24:MI:SS') * 24 * 60 * 60 * 1000) from account a where rownum = 1

Remarks

* 24 (hours)

* 60 (min)

* 60 (seconds)

* 1000 (Ms)

The above is all the contents of the article "how to calculate the time difference in oralce". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!

Tags: Time time difference content article value interest remarks fields guys partners hours data more query system knowledge type system industry information information channel Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS Microsoft Apple Huawei Xiaomi