Date-time info - when the last time any new record is inserted in a table

Hi all

is it possible to get information from Date and time - when the last time any new record is inserted in a table without triggers...?

Thanks in advance.
/ Shakeel

Hello

user11981535 wrote:
is it possible to get information from Date and time - when the last time any new record is inserted in a table without triggers...?

Insert only, I don't think it's possible.
But you can ora_rowscn pseudo-column and scn_to_timestamp the user function to get the time when the table was modified last:

Scott@my11g SQL>select scn_to_timestamp(max(ora_rowscn)) lstmod from t1;

LSTMOD
---------------------------------------------------------------------------
13-DEC-10 05.05.22.000000000 PM

Scott@my11g SQL>update t1 set val='stuff' where id=1;

1 row updated.

Scott@my11g SQL>commit;

Commit complete.

Scott@my11g SQL>select scn_to_timestamp(max(ora_rowscn)) lstmod from t1;

LSTMOD
---------------------------------------------------------------------------
13-DEC-10 05.07.19.000000000 PM

But I'm not wheither it is reliable to be used on the production database.

Tags: Database

Similar Questions

  • Is it possible that when the new record is inserted in a table then this empty inserted record is automatically displayed without scrolling?

    Mr President.

    Is it possible that when the new record is inserted in a table then this empty inserted record is automatically displayed without scrolling?

    Because I change the size property of the table 5 range and my new record is inserted at no 10.

    When I click the addRecord button the new parallel line does not appear, do scroll down to see it.

    I want that we don't have to scroll down.

    The line is displayed automatically.

    as shown in the photo my behavior of page.

    scrolling.png

    Concerning

    If you just need the newly created line to be visible,

    You can simply set contentDelivery = 'immediate' and displayRow = "selected".

    P.S. the blog mentioned above only.

    See you soon

    AJ

  • I want to know when the last time that change in my system windows xp sp3

    I want to know when the last change time in my system windows xp sp3 in Date & time difference are made. I want to know method.please give me to the subject of the information.

    OPEN Windows Explorer and in the right pane, right-click on the 'name' collum and select the option "update." Then, you should be able to check at any file was last chaged.

    J W Stuart: http://www.pagestart.com

  • Stolen phone. How can I check when the last time saved my phone to my laptop (without my iphone of course)?

    My iPhone was stolen. How can I check when the last time that I backed up my phone to my laptop without my iPhone?

    Click here and either use iTunes to check or browse to the path of the backup manually.

    (142338)

  • How can I identify the date when the last system restore was used to roll back the pc?

    Original title: how System Restore last used

    As the title suggests, how can I identify the date when the last system restore was used to roll back the pc?

    I can remove all restore points. I've used twice now the beta off Defender & he assures me
    the pc is clean Virgin.

    I have just got rid of a Trojan dropper & a Win 32/AmmyyAdmin. -(whatever it was!)

    I now seem to have acquired Windows Powershell along the way, gawd knows where!

    He was not here a few days ago and I don't have any idea where it is!

    What is it and should I be worried?

    Thank you

    Hello

    You can check this link:

    How to restore Windows XP to a previous state

    http://support.Microsoft.com/kb/306084

  • How to list the when a Table is created, and when the last change?

    Is there a way to know when a TABLE was created originally, and when the last change (=. for example, the last INSERTION of a line or UPDATE a line)?

    Peter

    Hello!

    select created,last_ddl_time from dba_objects where object_type = 'TABLE' and object_name = 'table_name'
    

    created ways to create object (table)
    last_ddl_time means when the structure of tables was the last modified time

    But there no opinion with dml last on the table. You must provide this with a few columns on table (Last_dml_time) that should be filled with
    Some database triggers

    Or if you have enabled AUDITING, then last time dml is registered also in audit trail

    T

  • Data is displayed when the cursor in the field, disappears when the cursor leaves the field

    I was given a simple Acrobat form with the data already present in the fields.  Even if the form field property is Visible on all fields, the data are visible when the cursor is on the ground.  As soon as the cursor leaves a field, the data disappear.  When I print the PDF, the data do not appear.

    I noticed that if I change the value of the field (e.g., add a period at the end), then the value disappears more.

    Anyone know why that would happen?

    Thanks in advance.

    Alice

    This is the appearance.

  • Clear HOWTO #{securityContext.authenticated} when the user opens a new tab in the browser

    Hello world

    I use a template for my ADF Application, so I make the application menu depending on whether the user is authenticated or not, if the menu is not displayed in the login page and use a common template for all my pages:

    rendered = "#{SecurityContext.Authenticated} '"

    My problem is that the value remains, so I would like to know what is best practice to turn it off when the user opens a new tab, or maybe my approach is quite wrong?

    Thanks experts!

    Jose.

    Hello

    I changed the method, so I give the menu according to a 'login' property in a managed bean:

    With the corresponding accessor:

    public boolean isLoginPage() {}

    Var currentPage = FacesContext.getCurrentInstance () .getViewRoot () .getViewId ();

    If (currentPage.contains ("login")) {}

    return (true);

    } else {}

    Return (false) End Function

    }

    }

    Thanks for your help!

    Jose.

  • Identify when the last update occurred

    I have two tables I need to unite. A table has dates that occur for events.

    with date_table as (
    select 1 ID_Key,to_date('4/1/2013','mm-dd-yyyy') date_val from dual union all
    select 1 ,to_date('4/2/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/3/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/4/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/5/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/6/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/7/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/1/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/2/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/3/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/4/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/5/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/6/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/7/2013','mm-dd-yyyy')  from dual 
    )
    

    The other table there when was the last time the ID_Key has been updated

    with Update_table as (
    select 1 ID_key,to_date('3/12/2013','mm-dd-yyyy') Last_Update from dual union all
    select 1 ,to_date('4/5/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('3/1/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/2/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/4/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/6/2013','mm-dd-yyyy') from dual
    )
    

    I would get the following table

    with end_table as (
    select 1 ID_Key,to_date('4/1/2013','mm-dd-yyyy') date_val, to_date('3/12/2013','mm-dd-yyyy') last_Update from dual union all
    select 1 ,to_date('4/2/2013','mm-dd-yyyy'), to_date('3/12/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/3/2013','mm-dd-yyyy'), to_date('3/12/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/4/2013','mm-dd-yyyy'), to_date('3/12/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/5/2013','mm-dd-yyyy'), to_date('4/5/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/6/2013','mm-dd-yyyy'), to_date('4/5/2013','mm-dd-yyyy') from dual union all
    select 1 ,to_date('4/7/2013','mm-dd-yyyy'), to_date('4/5/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/1/2013','mm-dd-yyyy'), to_date('3/1/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/2/2013','mm-dd-yyyy'), to_date('4/2/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/3/2013','mm-dd-yyyy'), to_date('4/2/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/4/2013','mm-dd-yyyy'), to_date('4/4/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/5/2013','mm-dd-yyyy'), to_date('4/4/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/6/2013','mm-dd-yyyy'), to_date('4/6/2013','mm-dd-yyyy') from dual union all
    select 2 ,to_date('4/7/2013','mm-dd-yyyy'), to_date('4/6/2013','mm-dd-yyyy') from dual 
    )
    

    Any suggestions?

    Just join, help<=, then="" group="" by,="" and="" grab="" the="">

    with date_table like)

    Select 1 ID_Key, to_date (' 1/4/2013 ','mm-dd-yyyy') date_val of all the double union

    Select 1, to_date (' 4/2/2013 ','mm-dd-yyyy') of all the double union

    Select 1, to_date (' 4/3/2013 ','mm-dd-yyyy') of all the double union

    Select 1, to_date (' 4/4/2013 ','mm-dd-yyyy') of all the double union

    Select 1, to_date (' 4/5/2013 ','mm-dd-yyyy') of all the double union

    Select 1, to_date (' 4/6/2013 ','mm-dd-yyyy') of all the double union

    Select 1, to_date (' 4/7/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 1/4/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/2/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/3/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/4/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/5/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/6/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/7/2013 ','mm-dd-yyyy') of double

    ), Update_table as)

    Select 1 ID_key, to_date('3/12/2013','mm-dd-yyyy') Last_Update in double union

    Select 1, to_date (' 4/5/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 3/1/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/2/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/4/2013 ','mm-dd-yyyy') of all the double union

    Select 2, to_date (' 4/6/2013 ','mm-dd-yyyy') of double

    )

    Select dt.id_key, dt.date_val,.

    Max (UT.last_update) last_update

    of date_table dt.

    update_table ut

    where dt.id_key = ut.id_key

    and ut.last_update<=>

    Dt.id_key group, dt.date_val

    order of dt.id_key, dt.date_val

    /

    ID_KEY DATE_VAL LAST_UPDATE

    ---------- ----------- -----------

    1-01 - apr - 2013 12-mar-2013

    1-02 - apr - 2013 12-mar-2013

    1 03-Apr-2013 12 - mar - 2013

    1-04 - apr - 2013 12-mar-2013

    1-05 - apr - 2013 05 - apr - 2013

    1-06 - apr - 2013 05 - apr - 2013

    1-07-Apr-2013 05-apr-2013

    2-01 - apr - 2013 01-mar-2013

    2-02 - apr - 2013 02 - apr - 2013

    2 03-Apr-2013 02-apr-2013

    2-04 - apr - 2013 04 - apr - 2013

    2-05 - apr - 2013 04 - apr - 2013

    2-06 - apr - 2013 06 - apr - 2013

    2 07-Apr-2013 06-apr-2013

    14 selected lines.

  • ORA-01722: invalid number - when the last column has numbers that have a decimal separator

    Here are examples of data-

    FRT, 1.64, VAT, 23,36

    FRT, 1.64, VAT, 23,36

    When I try to convert 1.64 to_number everything is good, but when I do the same thing with 23,36 I get the following error

    ORA-29913: error in executing ODCIEXTTABLEFETCH legend

    ORA-01722: invalid number

    ORA-06512: at "SYS." ORACLE_LOADER', line 52

    I tried this query example

    Select to_number (CONSIGNMENT_NET_VALUE) as Col1 of DUMP_EXT

    Select to_number (CONSIGNMENT_NET_VALUE, '9999999999D' 99999', NLS_NUMERIC_CHARACTERS = ",". ") as Col1 DUMP_EXT-> 268906.1

    make the same mistake - any help greatly appreciated.

    T.

    Srini

    Try using:

    RECORDS DELIMITED BY newline

    Instead of:

    RECORDS DELIMITED BY '\n'


    on your table to create, in addition to just help to_number or to_number return with ' NLS_NUMERIC_CHARACTERS = ".," ' in your query, in the period before the comma as decimal separator comes before the grouping separator.

    What is probably happening is that your return to the line of the system data come from different East of your new line on the system that you load in.  You may need to experiment and

    Select dump (consignment_net_value) in the dump_ext;

    to determine what additional invisible characters, such as Chr (10) and Chr (13) can be added at the end of the number that you have to cut, so just using line feed does not work.  This is why it only happens with the numbers at the end of the line.

    Post edited by: BarbaraBoehmer

  • How to make an end, when the last piece is finished

    IM new to Flash

    Can someone tell me how to end a puzzle game where the final piece of the puzzle is to / collides with the last location, he'll then a scene from new movie with a different major and a text like "you win."  Here is the code of action drag drop with no end I did a scene 2 and im planning to go to the scene 2 (the one with txt and new background) once the puzzle is completed. I don't know how to code, I copied all of this online tutorial which is great, but not end. Also, scene 2 I want to put a BACK button where it goes back to the scene 1 (solve the puzzle thingy).  Im still new and have no history proggramming, any help is appreciated. Thankx.

    piece1_mc.addEventListener (MouseEvent.MOUSE_DOWN, dragStart1);
    function dragStart1(event:MouseEvent): void {}
    piece1_mc.StartDrag ();
    }

    piece1_mc.addEventListener (MouseEvent.MOUSE_UP, dragStop1);
    function dragStop1(event:MouseEvent): void {}
    piece1_mc.stopDrag ();
    If (piece1_mc.hitTestObject (holder1_mc) == true) {}
    piece1_mc.x = holder1_mc.x;
    piece1_mc.y = holder1_mc.y;
    }
    }

    piece2_mc.addEventListener (MouseEvent.MOUSE_DOWN, dragStart2);
    function dragStart2(event:MouseEvent): void {}
    piece2_mc.StartDrag ();
    }

    piece2_mc.addEventListener (MouseEvent.MOUSE_UP, dragStop2);
    function dragStop2(event:MouseEvent): void {}
    piece2_mc.stopDrag ();
    If (piece2_mc.hitTestObject (holder2_mc) == true) {}
    piece2_mc.x = holder2_mc.x;
    piece2_mc.y = holder2_mc.y;
    }
    }

    piece3_mc.addEventListener (MouseEvent.MOUSE_DOWN, dragStart3);
    function dragStart3(event:MouseEvent): void {}
    piece3_mc.StartDrag ();
    }

    piece3_mc.addEventListener (MouseEvent.MOUSE_UP, dragStop3);
    function dragStop3(event:MouseEvent): void {}
    piece3_mc.stopDrag ();
    If (piece3_mc.hitTestObject (holder3_mc) == true) {}
    piece3_mc.x = holder3_mc.x;
    piece3_mc.y = holder3_mc.y;
    }
    }
    piece4_mc.addEventListener (MouseEvent.MOUSE_DOWN, dragStart4);
    function dragStart4(event:MouseEvent): void {}
    piece4_mc.StartDrag ();
    }

    piece4_mc.addEventListener (MouseEvent.MOUSE_UP, dragStop4);
    function dragStop4(event:MouseEvent): void {}
    piece4_mc.stopDrag ();
    If (piece4_mc.hitTestObject (holder4_mc) == true) {}
    piece4_mc.x = holder4_mc.x;
    piece4_mc.y = holder4_mc.y;
    }
    }
    piece5_mc.addEventListener (MouseEvent.MOUSE_DOWN, dragStart5);
    function dragStart5(event:MouseEvent): void {}
    piece5_mc.StartDrag ();

    }

    piece5_mc.addEventListener (MouseEvent.MOUSE_UP, dragStop5);
    function dragStop5(event:MouseEvent): void {}
    piece5_mc.stopDrag ();
    {if (piece5_mc.hitTestObject (holder5_mc) == true)}
    piece5_mc.x = holder5_mc.x;
    piece5_mc.y = holder5_mc.y;
    }
    }
    piece6_mc.addEventListener (MouseEvent.MOUSE_DOWN, dragStart6);
    function dragStart6(event:MouseEvent): void {}
    piece6_mc.StartDrag ();
    }

    piece6_mc.addEventListener (MouseEvent.MOUSE_UP, dragStop6);
    function dragStop6(event:MouseEvent): void
    {
    piece6_mc.stopDrag ();
    {if (piece6_mc.hitTestObject (holder6_mc) == true)}
    piece6_mc.x = holder6_mc.x;
    piece6_mc.y = holder6_mc.y;
    }


    }

    In each section test you if there was a shot, when a stroke occurs, you must remove to prevent event listeners which allows the object to process again and then increments a counter so that you can check if all parts are recorded as having been abandoned... example...

    outside any other code, declare the variable

    var plantedCount:int = 0;

    then inside you event handler functions do something like the following:

    If (piece1_mc.hitTestObject (holder1_mc)) {}

    piece1_mc.x = holder1_mc.x;

    piece1_mc.y = holder1_mc.y;

    piece1_mc. RemoveEventListener (MouseEvent.MOUSE_DOWN, dragStart1);

    piece1_mc. RemoveEventListener (MouseEvent.MOUSE_UP, dragStop1);

    plantedCount += 1;

    if(plantedCount == 6) {}

    Stop (1, "scene2");

    }

    }

    Note: When the code is repeated in modes such as yours the fact usually indicates the code can be condensed by making it more generic in which the same functions are shared by all the parts rather than having sets of functions dedicated to each piece.

  • Why Firefox browser closes when the last tab is closed?

    When I close the last tab that I use, Firefox browser disappears. How can I keep Firefox browser will open for the next procedure without waiting for browser at startup?

    1. Type of topic: config in the address bar and press ENTER.
    2. Press the big button to ignore the warning.
    3. In the search box, paste browser.tabs.closeWindowWithLastTab
    4. In the search results, double-click browser.tabs.closeWindowWithLastTab to set its value to false.
  • If the data is empty when you use to_date(?,'yyyy/mm/dd') insert a file into db

    online form insert the? is user input, if the user entered the following works find, but if the input file is empty insert get an error, how to handle
    If the data is empty when you use to_date(?,'yyyy/mm/dd')
    Thank you

    Be more specific.

    You try to insert this in a column that is defined as not null?

    If so, you can choose a default value for the value that you want to use if the user leaves the field to the white screen.

    Or, better yet, use the validation of the front to prevent them from going into an empty space (or perhaps failed it there).

    However, if you still want to do it in the DB:

    Insert into table1 (non_null_date_col)
    values (to_date (nvl (?, '' 2199/12/31), "dd/mm/yyyy"));

  • After the last update any pages files won't open

    After the last update, I can't get pages to answer, and it will not be open to all the old files.  Help please!

    What specific version of Pages do you use on El Capitan. You need to know that before I can answer.

  • How can I detect when the last container in my stream is full?

    I have a bunch of related containers which I am flowing text through. How can I detect when the text has filled a container? There's an overflowPolicy then I guess it can be detected.

    Hello

    I used this:

    private function IsOverset(textFlow:TextFlow):Boolean

    {

    var zeComposer:IFlowComposer = textFlow.flowComposer;

    var iTextLen:int = textFlow.textLength;

    var iNoController:int = zeComposer.findControllerIndexAtPosition (iTextLen - 1);

    return (iNoController is-1);

    }

    HTH,

    J.

Maybe you are looking for

  • Unable to select the file in the dialog box in the Sierra

    I'm unable to select an image file in the "save for Web" in the finder window "save under" in Photoshop CC running on the Sierra. There are times where I need to save a new image using a similar name by selecting the existing file, which matches the

  • Windows 8.1 update on the Satellite L50T-A-11 t

    Hello I got my Toshiba Satellite L50T-A-11 t with Windows 8, the first few days, I got it so I installed Windows 8.1 of the 'market', but my computer sometimes does strange thing as "reboot of the desktop", all icons disappear, the taskbar disappears

  • Can not handle JGS524Ev2 starting from a different subnet

    Is the JGS524Ev2 locked down to only allow web management from local subnet? I used the utility ProSafe Plus to search and detect my new switch from a computer with an address of 192.168.1.0/24. It's the same subnet as my DHCP scope, the switch was d

  • Pavilion p6330f: replacement of the NIC on Pavilion p6330f

    The network card in my PC p6330f failed.  I checked with HP for a replacement could not find a. Apparently, it's made by RealTek GBE family.   I found some indications that it is one of the series of cards PCIe RT8111 but there is a number in this fa

  • How can I find my forgotten username and password to my WebAdmin?

    I am trying to access my Actiontec site to change my user name and password, but just after I type my default address (192.168.0.1) my WebAdmin appears and typing me my user and password, of course I forgot it requires!  Any thoughts on how I can get