HELP! how to find out when last time db started - Page 2
DBAsupport.com Forums - Powered by vBulletin
Page 2 of 2 FirstFirst 12
Results 11 to 14 of 14

Thread: HELP! how to find out when last time db started

  1. #11
    Join Date
    Sep 2000
    Posts
    128

    Thumbs up Nice One

    What I don't understand is I think I ran this earlier:

    select to_char(to_date(a.value, 'J') + (b.value/60/60/24), 'DD-MM-YYYY HH24:MI:SS')
    from v$instance a, v$instance b
    where a.key = 'STARTUP TIME - JULIAN'
    and b.key = 'STARTUP TIME - SECONDS'
    /

    and it came up with 22:10 ?!

    I type it in now and it comes up with 22:22!

    Guess there must be a suttle difference, but I've closed the SQL *Plus window it was in now.... Oh Well.!

    Thanks

  2. #12
    Join Date
    Sep 2000
    Posts
    384
    Why terry complicate when things can be made simple..
    Radhakrishnan.M

  3. #13
    Join Date
    Jun 2000
    Posts
    417
    because problem solving is cool :)

    plus now i know a bit more about dates.

    however getting the time the oracle processes connected seems like an easier way for general use :) just want to select where username is null so you don't have to filter through normal user sessions.

  4. #14
    Join Date
    Sep 2000
    Posts
    128
    Well, looking in v$instance in Oracle 8i is the easiest way of all.

    I just wondered how it was done from v$Instance in Oracle 7 - and I too learnt a little more about data handling.

    Why not just run:

    select min(to_char(LOGON_TIME,'dd-mon-yyyy hh:mi:ss pm'))
    from v$session

    That's even easier still for Oracle 7... Although once you have a query written, any can be used just as quickly :)

    [Edited by TerryD on 11-17-2000 at 12:37 PM]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width