Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2004
    Location
    vienna, at
    Posts
    27

    Unanswered: TSPITR: Convert SCN/SEQUENCE to date (oracle10)

    before i perform a TSPITR i have to check the view
    TS_PITR_OBJECTS_TO_BE_DROPPED.
    with until SCN or SEQUNCE i have to convert the SCN or SEQUENCE into
    DATE.

    how can i get the date for scn or sequence
    phh

  2. #2
    Join Date
    Sep 2003
    Location
    Virginia, USA
    Posts
    246
    do you means the ORA_ROWSCN pseudo column in your data tables? If that's what you want, then consider the following:

    column owner format a10;
    column tablespace_name format a10;
    column name format a15;
    alter session set nls_date_format = 'dd-MON-yyyy hh24:mi:ss';

    select * from ts_pitr_objects_to_be_dropped where tablespace_name = 'USERS';

    OWNER NAME CREATION_TIME TABLESPACE
    ---------- --------------- -------------------- ----------
    APP1 EMPLOYEE 11-JAN-2005 13:32:24 USERS

    select max(scn_to_timestamp(ora_rowscn)) from EMPLOYEE;

    MAX(SCN_TO_TIMESTAMP(ORA_ROWSCN))
    --------------------------------------
    11-JAN-05 01.48.33.000000000 PM

  3. #3
    Join Date
    Dec 2004
    Location
    vienna, at
    Posts
    27
    thanx
    the function scn_to_timestamp is exactly what i need
    i didn't find it because i searched for scn to date
    phh

Posting Permissions

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