DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: insert date and ime stamp in table

  1. #1
    Join Date
    Dec 2002
    Posts
    28

    insert date and ime stamp in table

    How do I insert the date and time stamp in a table. At present i insert values (sysdate).

    How do I get date and time.

    Please advise.

  2. #2
    Join Date
    Nov 2002
    Location
    Geneva Switzerland
    Posts
    3,142
    SYSDATE includes date & time. Show both with:
    Select to_char(date_stamp_column,'DD-MON-YYYY HH24:MI:SS') From etc etc etc

  3. #3
    Join Date
    Aug 2002
    Location
    Colorado Springs
    Posts
    5,253
    sysdate is is date + time.

    to see the time portion, either ...

    Code:
    alter session set nls_date_format = 'DD-Mon-YYYY HH24:mi:ss';
    select my_date from my_table;
    .. or ..

    Code:
    select to_char(my_date,'DD-Mon-YYYY HH24:mi:ss') from my_table;
    David Aldridge,
    "The Oracle Sponge"

    Senior Manager, Business Intelligence Development
    XM Satellite Radio
    Washington, DC

    Oracle ACE

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