Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Difference of Timestamps from two different tables.

4243516Sep 14 2020 — edited Sep 14 2020

HI Team,

I have below queries:

1. Am trying to subtract last modified date timestamp of one table from another with below query but not getting the results. Like this I have to do for 15 more tables which are dependent on each other execution. Basically am trying to fetch the 'Execution time' for each:

SELECT TO_CHAR(a.LST_MOD_TS, 'HH24:MI:SS') T1,

TO_CHAR(b.LST_MOD_TS, 'HH24:MI:SS') T2,

T1-T2

FROM a JOIN b ON a.RCD_SEQ_ID=b.RCQ_SEQ_ID

2. For the first query i need to find its run time by subtracting 12 AM from its last modified date.

Please help me with the query for above.

Thanks,

Comments
Post Details
Added on Sep 14 2020
7 comments
1,634 views