How to find latest entry in the table according to time

how to find latest entry in the table according to the time
is there any function module to do so
\[removed by moderator\]
Edited by: Jan Stallkamp on Aug 25, 2008 4:39 PM

If you want to read the entry from an internal table,
sort the internal table in the descending order by the time and
delete adjacent duplicates by comparing the fields other than time and the internal table will have the latest record.
Suggestion: instead of only time try to have one more field called date with the time combination

Similar Messages

  • How to find delete entries in custom table

    We have a custom table with table maintenance in Production. Some one deleted all the entries from the table. Can you please let me know how to retreive the old entries from the table and how to check who deleted the entries.

    hi rama,
    Please refer to the below given link,
    I think it will sove ur problem,
    Reward points if usefull,

  • How to find multiple entries in the Directory

    my directory contains lot of multiple entires and I want to find out is there a easier method by a script or command to find out all the mutiple entries in the directory.
    Message was edited by:
    [email protected]
    Message was edited by:
    [email protected]

    Are you talking about entries that have been renamed because of a Replication Naming conflict (like the entry was added on 2 masters at the same time) ?
    If so, please check the Administration Guide, Replication section.
    If you were talking about something else, please be more explicit. Directory Server does not allow you to create multiple entries with the same name. DNs are unique.

  • How to find  latest updating row in a table

    How to find latest updating row in a table

    ADF 7 wrote:
    SELECT *  FROM Table WHERE lastupdTimestamp = (SELECT MAX(lastupdTimestamp) FROM Table)lastupdtimestamp - holds and date an time of an records when it last updation takes place in table.
    lastupdtimestamp is a column in my table.And how will this make sense in the scenario I've described, where UserA does an update before UserB, but commits the update after UserB's commited update? And add UserC and UserD and a 1000 more users to this scenario where concurrent updates happen.
    What actual time does this lastupdtimestamp contain and represent? And why? How is that lastupdtimestamp used in business logic and processing? Or is it just a silly-bugger-let's-add-somekind-of-time column to that table that essentially meaningless?
    Not saying that one should never add such a timestamp based column. Simply that one needs to understand WHAT it contains and it needs to be SENSIBLY used within the data model.
    However, in my experience such columns are often slapped on afterwards, never featured in the actual data model designed, and is then used without a second though that the database and its data is a multi-user and multi-process system. And things happen at the same time. And things overlap (serialisation is the exception - not the rule).

  • How to select alternate entries from the database table

    Hi Experts,
    can u help me, how to select alternate entries from the database table.

    As there is no concept of sequence (unless there is a field specifically included for the purpose), there is no meaning to "alternate" records.
    What table do you have in mind, what data does it hold, and why do you want alternate records?

  • How to find latest updated tables in current schema.

    I am in 3rd line support work, jobs(unix shell scripts) are running on daily at scheduled time.
    Regarding to my work, i need to found latest updated tables.
    How to find latest updated tables in current schema.
    please guide me.
    Thanks and Regards,

    duplicate thread
    Answers on other thread: How to find latest updated tables in current schema.

  • How to find workarea ID for the work area name.

    Hi Experts..
    How to find workarea ID for the work area name.(Work area name CCIHT_WAH-WAID and I want to fetch characteristic data from table AUSP matching the OBJEK field,but I only have Work area name).Can anybody help me to find tables or relationship between Workarea ID and Workarea name for the same.I am using TCODE - CHIB02.Once I select a workarea and click on IHS Data button,I get data for that workarea.I need to find where this data comes from and How is this fetched.
    Points would be rewarded for helpful answers..
    Kunal Halarnakar

    U want to fetch the workarea description ?
    we can fetch it from CCIHT_WALD table with the RECN value.
    The informations are stored in AUSP table with the characterstic(ATINN) value.

  • How to populate multiple entries to Bapi Table

    Hi all,
      How to populate multiple entries to Bapi Table.....
    Here is the code(in component controller)
      Z_Recr_Apply_Point_Input request = new Z_Recr_Apply_Point_Input(WDModelScopeType.TASK_SCOPE);
           int  size = wdContext.nodeApplicants().size();
                for(int i = 0 ; i < size ; i++)
                    String isselected = wdThis.wdGetContext().nodeApplicants().getElementAt(i).getAttributeAsText("Appl_Number");
                     if(isselected == "true")
                               com.models.veteranpoint.Zrecr_Aplno appid = new
    I want to pass the selected input field to bapi..
    Please tel me where i pass the input field...
    Please correct my code...
    Thanks & regards
    Mathi s

    Steps to insert multiple entries to BAPI table.
    1.Create an instance for BAPI input
    2.Bind the instance to the Node of the BAPI input
    3.Create instance of the Structure(BAPI table) to which input has to be added.
    4.Set the input values to the Structure instance.
    5.Add the instance to the BAPI input.
    From the given example,I assume Z_Recr_Apply_Point_Input  is the BAPI Input and as Structure
    Step 1:
    Z_Recr_Apply_Point_Input request = new Z_Recr_Apply_Point_Input(WDModelScopeType.TASK_SCOPE);
    Step 2:
    Steps 3 & 4:
    int size = wdContext.nodeApplicants().size();
    for(int i = 0 ; i < size ; i++)
    String isselected = wdThis.wdGetContext().nodeApplicants().getElementAt(i).getAttributeAsText("Appl_Number");
    if(isselected == "true") appid = new;
    Step 5:
    Viji Priya

  • CUA:  Wrong entries in the table USZBVSYS

    Hi All,
    While searching a particular user access to the child systems via SUIM - > Users by system, the report given output that the user have access to so and so system. Whereas that user already deleted and there is no user account in CUA and the respective child system.
    When i search in the table USZBVSYS, that user having a entry to that child system with status S.
    May be due to some old IDOC get processed and made an entry in this table but physical the changes were not made either in CUA or in child system.
    Now my concern is how to delete such type of entries in the table USZBVSYS?
    SAP recommended not to use the report RSUSR_CUA_CLEANUP_USZBVSYS and i think it can be resolve only by manually method to create and delete.
    Kindly let me know you opinion pls.

    RSUSR_CUA_CLEANUP_USZBVSYS cannot work in this case, as you have 'S'-entries for the user section  in uszbvsys. The report will clean up only entries with D,A or X entry for the user entry.
    So there seems to be no automated standard report for your query.
    I suggest to collect the user-IDs you need to remove, copy them into SU10, recreate them for the required systems and delete them
    afterwards again.
    Make sure, that nobody processes cua-idocs manually in any of your systems of the cua. Only use scul.
    b.rgds, Bernhard

  • How to validate an entry in a table?

    I have a (single column) table view linked to an NSArrayController that has a custom class definition as its 'Class Name'. I also have KVC compliant methods to populate the array controller within my 'model'. I can see the 'countOf...' and 'objectIn...AtIndex' methods being called and the table contains the correct data.
    I have the 'Validates Immediately' option set on both the table column binding and the controller content array binding.
    My problems come when I alter the contents of an entry in the table. Firstly, the only 'validate...:error:' method that is called is on the custom class for the field that is updated.
    Secondly, the 'insertObject:in...:AtIndex' and similar (especially the 'replaceObjectIn...AtIndex:withObject:') methods are not called.
    I have checked and rechecked that the KVC names include the correctly capitalised name of the class.
    How can I get the validation (and other) routines to be called?


  • Delete any entry in the table before adding an entry?

    Hello ABAP Experts,
    I have the data in the work area. I can modify / update / insert to the table.
    How to write the ABAP code for this situation.
    1) to delete any entries in the table
    2) update this entry
    so finally always there would be only one entry.
    Suggestions appreciated.

    Delete the entries of table by this stmt.
    DELETE FROM (dbtabname).
    Then insert the values from workarea
    INSERT INTO dbtab VALUES <work_area>.
    And u can upadte the entry with values of workarea by this stmr.
    UPDATE (dbtabname) FROM wa.
    Dont use MODIFY. It will add a new record if its a new entry.

  • How   to  find  global  index  in partition table

    Hi guys ,
    need one help
    How to find global index on partition table
    How to find local index on partition table
    Need query
    Thanks in advance
    Edited by: nav on Feb 17, 2012 6:51 AM

    nav wrote:
    Hi Solomon,
    so I have to identify partition & index are created or not,
    also I have check the status of index ( both global and local)So what's the problem? Table/index partition is an object, so you can query DBA_OBJECTS:
      WHERE OWNER = partitioned-table-owner
        AND OBJECT_NAME = partitioned-table-name
    /This will give you partitions created today. So if you run this right after your job (I hope your job doen't run too close to midnight), you'll get table partition name your job created. Same logic can be applied to indexes.

  • How to find out important fields in table like MARA?

    How to find out important fields in a table for example like MARA?
    Details: In R/3 or ECC table for example MARA;
    1) How to find out what are the important fields?
    2)Does the table have only key figures not characteristics right?
    3) There are so many tables in FI; Can you please tell me what are the important tables?
    4) There is any easy automatic way to figure out that the particular datasource for example 2lis_02_item is pulling data from so and so table. I like to know the process not the results please.
    Thanks in advance.

    Hi York,
       Let me go by points:
    1. There is nothing like important fields ... The question could be Key fields ... the fields which identify a record uniquely ... If you go to SE11, and go inot the dispaly of MARA table ... you will see that there is tick mark under key to indicate that the field is a key field ... All the fields which are so marked would identify a record in the table uniquely. If your question is otherwise ... (Important fields) ... then it depends on the purpose you wnat to meet ... Some fields might be important for me but not for you ... so there is not hard nad fast rule for important fields.
    2. No... Tables in R/3 or ECC would contain both Key figures and characteristics.
    3. Important tables in FI would be BKPF, BSEG and BSET.
    4. The procedure for finding out which table are used by say 2lis_02_item would be different from that of other non LO/LIS extractors.
    In case of LO/LIS turn on the trace (below process) while populating the setup tables and for thoers while executing RSA3.
    1. Open one session and go to ST05, click on "Activate Trace"
    2. Open another session and execute the transaction you want to track for the tables it is going to hit.
    3. Go to the session of point 1 above and click on DEACTIVATE TRACE
    4. Click on DISPLAY Trace
    This will show you all the tables that were hit while extracting data. Point to remember here is ... it will hit some standard tables as well ... so you will have to filter out what is relevant from what is not.
    Hope this helps.
    best regards,

  • Problem with the XI-Audit log entries in the table "XI_AF_MSG_AUDIT"

    I have an async-szenarios for PO:
    We send Idoc's from SAP ERP to a WebService via SOAP. And we take Ack's. We use Integrationsprocess with deadline block to catche the errors after the retrying (three times) and to send they via e-mail.
    Our problem is, the number of the audit logs in the table "XI_AF_MSG_AUDIT":
    In the RTW only we see one audit log (with three retries) in an error case. But in the table XI_AF_MSG_AUDIT there are about 76 entries for the same audit log in the error case and about 20 entries in the case of the succuessfull processing.
    This number of the entries in the table causes problem with the size of the redo log file and delete job of cours the large size of the table and therefore problem on the data base. The table can not be controlled. The delete job can not run and cancels every time due this redo log problems
    What can cause that?
    How can it be prevented, that so much entries are not be made in the  table "XI_AF_MSG_AUDIT".
    Best regards

    Hi Gueltekin,
    I am only aware of the general property auditLogEnabled of J2EE Engine Service SAP XI AF Core, which controls in general (default = true) that entries in the AF Message Audit log are written at all.
    (see [|])
    I assume that your scenarios in the error case is sending up to three messages and for each message the number of audit log infos are created. You might want to check the detailed entries in the log and see from where they are comming, you might use customer modules etc. as well.
    Best regards,

  • Multiple entries in the table cabn

    Can Anyone tell me how is it possible to have multiple entries of the same "atnam" field in the table CABN.
    It has something to do with changing number.
    Because I used a wrong select-instruction e.g.
    select atnam in charact where .... IN ....
    So, I shoud used
    select DISTINCT atnam in charact where .... IN ....
    So, I'm gone need to try to put multiple entries in the table to check, if it's working well.
    Thanks a lot.
    Best Regards,

    If I understand your Q - you mean there are two ATINN for the same ATNAM in your CABN table?
    I dont think that's possible. If you check CT04 and try to create a new characteristic with same name as an existing one - it will give you a warning and prevent creation.
    Since you say it's a standard characteristic - please mention the characteristic name (ATNAM)?

Maybe you are looking for

  • Adobe Photoshop CC 2014 For Mac - Text Cursor Not Stable!

    I recently installed some fonts on my Mac Pro and besides the fact that Microsoft Office 2011 now crashes upon starting any program within that suite, I've also noticed that Photoshop, specifically the text cursor when you go to create or edit text,

  • "Program was terminated by signal 6" in R12

    Hi All, Purchasing report is completed with error of signal 6. Please find the attached below log file details. Please advise how to resolve this issue in R12. XXPRPOP module: Printed Purchase Order Report +-------------------------------------------

  • Intermittend connection problem from J2EE (separate) engine to ABAP

    When i run the test report FP_CHECK_DESTINATION_SERVICE the first time it works and returns the number of bytes transmitted. The second time it does not . The third time it works , the fourth time it does not etc etc etc  No matter how long I wait in

  • My iphone 5c the sound doesn't work only with earphone.

    my iphone 5c the sound doesn't work it works only with earphone.

  • About Oracle courses

    I have taken the next courses and I have the certification Oracle Certified Associate - Oracle 10g SQL - Oracle 10g workshop I - Oracle 10g workshop II - Oracle Performance Tuning In order to get the properly knowledge or continuing my education in O