How to change Sysdate of Oracle Database - Page 2
DBAsupport.com Forums - Powered by vBulletin
Page 2 of 4 FirstFirst 1234 LastLast
Results 11 to 20 of 33

Thread: How to change Sysdate of Oracle Database

  1. #11
    Join Date
    May 2002
    Posts
    2,645
    This makes my head hurt. Please stop.

  2. #12
    Join Date
    Jul 2002
    Location
    Lincolnshire, IL
    Posts
    203
    Hey...sorry guys...there was something great I was missing....sorry friends...I got the problem...sorry pando and thanks Slimdave...
    Sandy
    "Greatest Rewards come only with Greatest Commitments!"

  3. #13
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    guess

    select to_char(sysdate, 'YYYY-MM-DD HH24:MI:SS') from dual;

    !date

    worked


  4. #14
    Join Date
    Jul 2002
    Location
    Lincolnshire, IL
    Posts
    203
    Mr. Pando...would you like to take this problem as a challenge...My unix server date and my Oracle date is different. I tried to change my Unix date using 'date' command and after that I issued select sysdate from dual...still it was showing old value...it's a challenge for you...
    "Greatest Rewards come only with Greatest Commitments!"

  5. #15
    Join Date
    May 2002
    Posts
    2,645
    Originally posted by sandycrab
    Hey...sorry guys...there was something great I was missing....sorry friends...I got the problem...sorry pando and thanks Slimdave...
    Sandy
    Mr. Pando...would you like to take this problem as a challenge...My unix server date and my Oracle date is different. I tried to change my Unix date using 'date' command and after that I issued select sysdate from dual...still it was showing old value...it's a challenge for you...
    Do you have it solved or not????

    Why don't you post the results of the select statement and the !date output?

  6. #16
    Join Date
    Jul 2002
    Location
    Lincolnshire, IL
    Posts
    203
    Q : select to_char(sysdate, 'YYYY-MM-DD HH24:MI:SS') from dual;
    Output : 2003-02-03 09:25:45

    Command: !date
    Output : Wed Feb 5 16:40:22 CST 2003
    "Greatest Rewards come only with Greatest Commitments!"

  7. #17
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    It's not a challenge because what you say is not LOGICAL at all, it's how Oracle works, if you see different date then you have problem with your platform and not Oracle's fault.

    Or you are comparing local date with remote server date

    do

    sqlplus

    select host_name from v$instance;

    !uname -a

    select to_char(sysdate, 'YYYY-MM-DD HH24:MI:SS') from dual;

    !date

    and post results here

  8. #18
    Join Date
    Dec 2001
    Location
    UK
    Posts
    1,684
    I did extensive Y2K testing on a system for Procter & Gamble in Cincinatti (USA) and Dartford (UK) and I can assure anyone out there that Pando is correct, Oracle definitely gets it's date from the OS.

    Pando - Close your eyes and take several long deep breaths. It's gonna be OK

    Cheers
    Tim...
    OCP DBA 7.3, 8, 8i, 9i, 10g, 11g
    OCA PL/SQL Developer
    Oracle ACE Director
    My website: www.oracle-base.com
    My blog: www.oracle-base.com/blog

  9. #19
    Join Date
    Jan 2001
    Posts
    2,828
    Hi

    ohh..my gawd..just how patient pando..is...


    regards
    Hrishy

  10. #20
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    My suspicion:

    He/she is performing all this on the workstation, not on the server where database is running. So select from dual shows a date of the host runing the database, while !date shows the date of the client machine.
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

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