Read Archive Object direct with Offset

Dear all
i need to access an invoice into the Archive. I know the archivename and the offset.
I open my archive and this works well. Now i have not found a possibility to access directly to the right object with the right offset.
I use now the FM ARCHIVE_GET_NEXT_OBJECT and check the offset, but this takes a long time on big archives. How can I access the object directly with the offset?
Herbert

Hi Jorge,
If you want to read the data for reporting or
control purposes, you have to write a report, which reads data from the archive files sequentially.
Alternatively, you can also use the Archiving Information System (AS). This tool enables you to define an
InfoStructure, and create reports based on these InfoStructures. The InfoStructures define an index for
the archive file data. At the moment, the archiving process in the BW system does not fill the
InfoStructures during the archiving session automatically. This has to be performed manually when
needed.
Another way of displaying data from the archive file is by using the ‘Extractor checker’ (TCODE RSA3).
Enter the name of the export DataSource of the respective data target (name of the data target preceded
by ‘8’), and choose the archive files that are to be read. The extractor checker reads the selected archive
files sequentially. Selection conditions can be entered for filtering but have to be entered in in internal
format (e.g. 20011130 for date 30.11.2001).
Anup.

Similar Messages

  • Archiving Object - Entry missing in Customizing table for object Z*********

    Hello friends,
    We have created a archiving object in transaction AOBJ. However when i enter this object in SARA, we get this error message.
    "Entry missing in Customizing table for object Z******* "
    I have matched my object with few other archiving objects and things looks similar.
    Have you faced this kind of problem..
    thanks
    ashish

    Hi,
    I checked and i can see entry for ZSCS_TRAFO object in AOBJ.
    But when i enter ZSCS_TRAFO, i get this error :
    Entry missing in Customizing table for object ZSCS_TRAFO
    Message no. BA057
    Diagnosis
    A function cannot be executed due to a missing table entry.
    Procedure
    Please create an entry for the archive object ZSCS_TRAFO with the AOBJ transaction.
    However, a few other Z objects works well.
    thanks
    ashish

  • Reading archived data of different archive objects in Z programs

    Hi,
       I have Z programs which are getting data from various tables. Now i needt to read archived data of those tables in my Z programs also. i.e. i need to modify those programs so that data archived for those tables should also be extracted. Now for exmple if the program is fetching data from MARA, EKKO, LIKP, KONP tables based on certain selection criteria, then how do i fetch archived data for same criteria as each of these tables may belong to different archive objects ? Please help me. Thanks in advance.

    Hie Naganath
    Using transaction SARA you can identify the archive objects for the tables you want to use. 
    For material master you can use object MM_MATNR, for Purchasing documents use object MM_EKKO, for conditions use SD_COND and for deliveries use object RV_LIKP.
    Retrieve the archive key and offset from table ZARIXMM5 (for Purchasing documents) for your select options and pass the offset and key to function ARCHIVE_READ_OBJECT to get the handle and then pass the handle to function ARCHIVE_GET_TABLE to read the record.  Have a look at the below code
    select archivekey archiveofs into corresponding fields of table lt_arch_keys
                   from zarixsd1 "SD Index table for billing documents
                  where vbeln in s_docrng
                    and kunrg in s_arc_kn
                    and fkdat in s_arc_dt
                    and fkart in s_arc_rt
                    and vkorg in s_arc_og.
      loop at lt_arch_keys assigning <fs_lt_arch_keys>.
    *Read information from archive
        call function 'ARCHIVE_READ_OBJECT'
          exporting
            object         = 'SD_VBRK'
            archivkey      = <fs_lt_arch_keys>-archivekey
            offset         = <fs_lt_arch_keys>-archiveofs
          importing
            archive_handle = ls_handle
          exceptions
            others         = 1.
    *Get the requested header detail data for billing document
        call function 'ARCHIVE_GET_TABLE'
          exporting
            archive_handle          = ls_handle
            record_structure        = 'VBRK'
            all_records_of_object   = 'X'
            automatic_conversion    = 'X'
          tables
            table                   = lt_vbrk "Header data
          exceptions
            end_of_object           = 1
            internal_error          = 2
            wrong_access_to_archive = 3
            others                  = 4.
    *Get the requested line item detail data for billing document
        call function 'ARCHIVE_GET_TABLE'
          exporting
            archive_handle          = ls_handle
            record_structure        = 'VBRP'
            all_records_of_object   = 'X'
            automatic_conversion    = 'X'
          tables
            table                   = lt_vbrp "Line item data
          exceptions
            end_of_object           = 1
            internal_error          = 2
            wrong_access_to_archive = 3
            others                  = 4.
        clear: ls_vbrk.
        loop at lt_vbrp assigning <fs_lt_vbrp>.
          read table lt_vbrk into ls_vbrk with key vbeln = <fs_lt_vbrp>-vbeln.
          move-corresponding <fs_lt_vbrp> to lt_archive_records.
          move-corresponding ls_vbrk to lt_archive_records.
          append lt_archive_records to gt_archive_records.
        endloop.
      endloop.
    Do the same for your material master and condition records as well.
    regards
    Isaac Prince

  • Archiving object in open hub with logical file name

    Hello,
    I am trying to use an open hub with a logical file name.
    By the SAP help looks like you have to use/define a archiving object:
    http://help.sap.com/saphelp_nw70/helpdata/en/e3/e60138fede083de10000009b38f8cf/frameset.htm
    http://help.sap.com/saphelp_nw70/helpdata/en/8d/3e4ec2462a11d189000000e8323d3a/frameset.htm
    Steps 1 and 2 of "Defining Logical Path and File Names" are done and tested:
           1.      Definition of the logical path name
           2.      Definition of the logical file name
           3.      Assignment of the logical fine name for the archiving object
    But is it not clear to me if an archiving object is suppose to be used, which one then?,  or if you have to create a new archiving object, with which characteristics?
    Any help welcome,
    Alberto.

    Alberto,
    Can you explain what you are trying to do. Are you trying to archive data from a BI object or are you trying to export data out of a BI object using open hub.

  • Count total number of record of table with deletion from archiving object

    Does anyone know is there any SAP standard program to count the total number of record of the table with deletion from Archiving Object and display in repprt?

    Not sure of the question. Are you looking to get the sql "select count(*) from table" from using the TopLink expression framework or are you getting that SQL already and want something else?
    If you are looking just to get the count from a table/class, you can use a ReportQuery:
    ReportQuery rquery = new ReportQuery(ClassToQueryOn.class);
    rquery.addCount(); //equivalent to count(*);
    session.executeQuery(rquery);
    You can use a report query to return data instead of objects, and use selection criteria just like a normal read query.
    Best Regards,
    Chris

  • Archiving objects from tabel QMEL, JEST, JCDS with priotype SR

    Hi,
    In tx SARA I can find 5 archivingobjects to archive data from table QMEL.
    CM_QMEL
    NM_QMEL
    PM_QMEL
    QM_QMEL
    SM_QMEL
    It looks they correspond to the priotypes named in field ARTPR in table QMEL.
    CM, GO, PM, QM, SL, SM, SR
    Our table QMEL consists of records with priotype SR.
    My question: Which object can I use to archive?
    Regards Marco

    Hi,
    I haven't found any documentation related to this so what you can do is spend around 25 mins and test it to see which archiving object suits your need. Try the following in a test environment:
    1. Complete a notification and flag it for deletion.
    2. For every archiving object (you have 5) create a test variant for the pre-processing program. In this variant specify the notification ID in the notification field and select run in "Test mode".
    3. Execute the pre-processing program for each archiving object using the variants that you created and then check their output, you should get an archiving object that selected for archiving this notification and then you can go on with that archiving object.
    Please let me know if this helps.

  • How to read appended objects from file with ObjectInputStream?

    Hi to everyone. I'm new to Java so my question may look really stupid to most of you but I couldn't fined a solution by myself... I wanted to make an application, something like address book that is storing information about different people. So I decided to make a class that will hold the information for each person (for example: nickname, name, e-mail, web address and so on), then using the ObjectOutputStream the information will be save to a file. If I want to add a new record for a new person I'll simply append it to the already existing file. So far so good but soon I discovered that I can not read the appended objects using ObjectInputStream.
    What I mean is that if I create new file and then in one session save several objects to it using ObjectOutputStream they all will be read with no problem by ObjectInputStream. But after that if in a new session I append new objects they won't be read. The ObjectInputStream will read the objects from the first session after that IOException will be generated and the reading will stop just before the appended objects from the second session.
    The following is just a simple test it's not actual code from the program I was talking about. Instead of objects containing different kind of information I'm using only strings here. To use the program use as arguments in the console "w" to create new file followed by the file name and the strings you want save to the file (as objects). Example: "+w TestFile.obj Thats Just A Test+". Then to read it use "r" (for reading), followed by the file name. Example "+r TestFile.obj+". As a result you'll see that all the strings that are saved in the file can be successfully read back. Then do the same: "+w TestFile.obj Thats Second Test+" and then read again "+r TestFile.obj+". What will happen is that the strings only from the first sessions will be read and the ones from the second session will not.
    I am sorry for making this that long but I couldn't explain it more simple. If someone can give me a solution I'll be happy to hear it! ^.^ I'll also be glad if someone propose different approach of the problem! Here is the code:
    import java.io.*;
    class Fio
         public static void main(String[] args)
              try
                   if (args[0].equals("w"))
                        FileOutputStream fos = new FileOutputStream(args[1], true);
                        ObjectOutputStream oos = new ObjectOutputStream(fos);
                        for (int i = 2; i < args.length ; i++)
                             oos.writeObject(args);
                        fos.close();
                   else if (args[0].equals("r"))
                        FileInputStream fis = new FileInputStream(args[1]);
                        ObjectInputStream ois = new ObjectInputStream(fis);
                        for (int i = 0; i < fis.available(); i++)
                             System.out.println((String)ois.readObject());
                        fis.close();
                   else
                        System.out.println("Wrong args!");
              catch (IndexOutOfBoundsException exc)
                   System.out.println("You must use \"w\" or \"r\" followed by the file name as args!");
              catch (IOException exc)
                   System.out.println("I/O exception appeard!");
              catch (ClassNotFoundException exc)
                   System.out.println("Can not find the needed class");

    How to read appended objects from file with ObjectInputStream? The short answer is you can't.
    The long answer is you can if you put some work into it. The general outline would be to create a file with a format that will allow the storage of multiple streams within it. If you use a RandomAccessFile, you can create a header containing the length. If you use streams, you'll have to use a block protocol. The reason for this is that I don't think ObjectInputStream is guaranteed to read the same number of bytes ObjectOutputStream writes to it (e.g., it could skip ending padding or such).
    Next, you'll need to create an object that can return more InputStream objects, one per stream written to the file.
    Not trivial, but that's how you'd do it.

  • Read the text in object LFA1 with ID Z001

    Hi Guys,
    Can u please suggest me how can i read the text in object LFA1 with ID Z001.
    Actually my requirement is i have service agent in my internal table.
    Z002 is the current pro number..that is ready to use after using that update that current pro # Z002 with the next available in the range...(i.e Z001)
    Z001 contains range of Pro number.,. like 848 477 250 to 848 477 740
    asume you used the # 848 477 250 in one shipment, update the Z002 with the second one 848 477 251
    Can u please suggest me this how can i develop. Just send me the suggestions plese i will do that coding. Lookingforward your kind co operation.
    Regards,
    Ravi

    Basic call to function is as follows:
    CALL FUNCTION 'READ_TEXT'
      EXPORTING
        id                            = 'Z001'    "Text ID = 'Z001'
        language                      = 'E'       "English
        name                          = 'LFA1'    " Not sure if this is correct
        object                        = l_vendor  "Vendor with leading zeros
      TABLES
        lines                         = l_output   "Table of Structure  TLINE
    EXCEPTIONS
       ID                            = 1
       LANGUAGE                      = 2
       NAME                          = 3
       NOT_FOUND                     = 4
       OBJECT                        = 5
       REFERENCE_CHECK               = 6
       WRONG_ACCESS_TO_ARCHIVE       = 7
       OTHERS                        = 8.
    I am not sure I have the name and object exactly right - If you display one of the texts in the old style editor and use menu option Goto-->Header you can see these values.  Alternatively look in table STXH for text headers to see how the key is constructed.
    Andrew

  • Read program for archiving object

    How to find the read program for the given archive object.
    Which transaction is used for this purpose.
    Shree.

    HI Abishek,
    Thanks. I dont find read program for the Archiving object FI_FICA in AOBJ. How to find it .
    Shree.

  • I have a MacBook Air with Snow Leopard. I can read/write in both directions with 16 GB Fat32 drives but cannot with a 250GB NTFS drive.

    I have a MacBook Air. I also have a 250GB NTFS external drive which the Mac sees. i can copy and paste from the external drive to the Mac but not from the Mac to the external drive. However, I can go in both directions with a Fat32 16 GB flashdrive. Can anyone explain this to me?

    I've always recommented ext3 filesystem if you wanna use an external drive for both Windows and Mac OS as both can read and write to that filesystem.
    But obviously you'd have to format the drive (you can use Mac disk utility)

  • ByteArrayInputStream read with offset

    I have a ByteArrayInputStream that I want to read from specific position after initializing. So for example:
    byte [] bdata = //Some data
    ByteArrayInputStream bt = new ByteArrayInputStream(bdata);
    I want to be able to point to position 4 and read 8 bytes and then read 3 bytes pointing to position 6 starting from the next of last read byte, in this case position 12, since last read was 8 bytes from position 4. So if I have
    123456789ABCDEFGHIJKLMNOP
    first read would get me: 456789AB
    second read would get me: HIJ
    I was thinking of using read with offset but that is not quite working properly. May be I could use skip but I am not sure how it works.

    Are you reading binary data, or are you reading text? If it's text, why are you storing it in a byte array?
    If it's actually binary data, then look at the read(byte[] b, int off, int len) method, it lets you read len bytes from the off starting position. It stores what it reads in the b array.
    If it's actually text that you're trying to read, then use the Reader class instead. It's much like an InputStream, but designed for text instead.

  • Archiving Object Impact

    I  am trying to run some analysis for my customer - they are interested in knowing all ABAPs (SAP standard and Z-ABAP) that would be impacted if we archived certain data.
    I have tried looking at SE11 for specific tables but that is throwing up a lot of ABAPs.
    Does anyone know if there is a way in SAP (or some 3rd party tool) where by I can enter the archiving object (rather than the specific table) and for the system to return a list of ABAPs that are impacted by 1 or more tables with in that object.
    thanks in advance

    Shibu:
    EMMA archive should have no impacts, provided you are not using EMMA cases OR if you are archiving for periods which are no longer used in case management.
    regards,
    bill.

  • Archiving object for tables GLPCC and GLPCO

    Hi All,
      GLPCA table stores the actual line items in PCA and GLPCT table stores the totals records of PCA.
    What are the transactions which get affected in regular course by these tables?
       GLPCC - EC-PCA: Transaction Attributes
       GLPCO - EC-PCA: Object Table for Account Assignment
    There is no archiving object for the tables GLPCC and GLPCO when checked in DB15. What is the alternative for archiving the entries in those tables?
    Thanks in advance
    Regards
    Anupama

    Hello Anupama,
    The standard archiving objects for PCA are EC_PCA_ITM & EC_PCA_SUM. Most of the data is archived with above two objects.  Hence it would be better to use given archiving object. About 80% of data can be archived through standard archiving objects.
    For more information you may read SAP Data Management Guide.
    Regds
    Ambadas

  • Archiving object CRM_SEOPD in solution manager

    Hello,
    The self diagnostics for solution manager throws a warning under "Service Desk" functionality with message text "Critical number of incidents per support team or error reading volume". The detail display shows:
    Strategy for resolving the alert -  to start an archiving project for incidents using archiving object CRM_SEORD.
    Details of this Alert - 1. No support teams, i.e. business partner type organization (Message no. DSWP_SD127).
    Does anyone have a clue how to go about resolving this warning.
    Thanks,
    Asif

    Hello,
    For Archiving Support Desk messages you should refer to SAP Note  1329247 - Archiving Solution Manager Service Desk messages. It describes the process which is a two part process, one part in Solution Manager, the second part in CRM.
    This will resolve this issue.
    Glad to help!
    Regards,
    Paul

  • Archiving object in ECC

    hi gurus,
    need some procedure help in identifying archiving object in ECC system.
    i would like to what exactly do we look in TAANA and DB15 ,after sorting the largest and fast growing DB tables .
    TAANA basically shows the records and table entries. DB15 shows the relation between the table and archiving object.
    i need some inputs in identifying the right archiving object using these tools. I went through standard guides but I'm not getting a clarity.
    please assist

    Hello,
    For identifying the archiving object for respectable you can use DB15 transaction. Note that you should have some idea in archiving area so that is will be easier to conclude on archiving object.
    Your understanding on display of archived data is wrong.
    Archive data are stored in archive file non-readable format, while display SAP convert the data into readable format to user.
    This will not reload the data into tables while reading the archive data.
    Archive information system is very well build, it is easy to handle with business requirement on views & managing archive index table, so i would suggest to make use of archive information system to display from archive.
    Hope it will give some lights on display of archived data.
    -Thanks,
    Ajay

Maybe you are looking for