Regarding AUFK, AUAK / COSB tables

Hi all,
I am working on WIP Aging Report and for this, i need to extract the data from the AUFK and COSB tables. I was told to get all the AUFNR values from AUFK table and then the values of AUFK-AUFNR will match with COSB-OBJNR values excluding the first two letters. Is there any other way to implement this requirement as extracting data without 'where' clause in from AUAK or COSB tables results with huge amount of data.
Regards,

Hiya
Try something like this, you may need to amend for your purpose but the principle may work for you. If you don't already know, never do FOR ALL ENTRIES with an empty itab...
Regards,
KM
TYPES: BEGIN OF T_AUFK,
      AUFNR LIKE AUFK-AUFNR,
      OBJNR LIKE COSB-OBJNR,
       END OF T_AUFK.
DATA: IT_AUFK TYPE STANDARD TABLE OF T_AUFK,
      IT_COSB TYPE STANDARD TABLE OF COSB.
FIELD-SYMBOLS: <AUFK> LIKE LINE OF IT_AUFK.
* Get your order numbers
SELECT AUFNR INTO TABLE IT_AUFK
       FROM AUFK
       WHERE etc etc
IF NOT IT_AUFK IS INITIAL.
* Take 2 chars off AUFNR to give OBJNR
  LOOP AT IT_AUFK ASSIGNING <AUFK>.
    <AUFK>-OBJNR = <AUFK>-AUFNR.
    SHIFT <AUFK>-OBJNR BY 2 PLACES.
  ENDLOOP.
* Use OBJNR in the internal table to select from COSB
  SORT IT_AUFK BY OBJNR.
  SELECT * INTO TABLE IT_COSB
         FROM COSB
      FOR ALL ENTRIES IN IT_AUFK
         WHERE OBJNR = IT_AUFK-OBJNR.
ENDIF.

Similar Messages

  • Not able to get the data in COSB Table

    Hi Colleagues,
    I have created a Project and assign the WBS number to a Sales order and also have done all the settings in Result Analysis.
    But still not able to get the data in COSB table.
    Could you please suggest me the steps and process, Might be i have missed something..
    Thanks in Advance
    Regards
    Nitin

    Hi Ken,
    I have below mentioned requirement
    COSB will show value by object number and need to pass the object number to PRPS table to find the corresponding WBS element and then pass the WBS element to VBAP table to find the corresponding SO line item.
    Please let me know as Functional prospect what I have to do to bring this values in COSB table.
    Regards
    Nitin

  • Delete Variance data from COSB table for version 1

    Hi,
    We are trying to change the Valuation of version 1 from Legal to Profit center in OKEQ.
    While doing so, we are trying to remove variance indicator due to error message KT337.
    When trying to uncheck variance indicator for this version there is error message KV853.
    SAP per SAP note 337183, if there are any dependent entries in COSB table (CO Object: Total Variances/Results Analyses) we get this message.
    Now the question is how can i delete the variance data with version 1 from the table COSB.
    Message no. KT337 :
    Valuation variance from version "000"
    Diagnosis
    You are maintaining version 1 in controlling area 1000. The actual indicator is not active and at least one of the two indicators WIP and Variance are active. In this case, the valuation in version 1 must match the valuation of version '000'. This is not the case: 2 <> 0.
    Procedure
    Activating the indicators WIP and Variance with the actual indicator being inactive at the same time requires valuation 0.
    Message no. KV853
    Variance calculation cannot be reset - there are dependent entries
    Regards
    Raghu
    Edited by: Raghu Ram Thatavarthy on Nov 16, 2011 3:35 PM
    Edited by: Raghu Ram Thatavarthy on Nov 16, 2011 3:36 PM

    You may need to contact the SAP SLO (System landscape optimization) team

  • Link between AUFK and BKPF table

    Hi all,
    Can anyone tell me the link between AUFK and BKPF table.
    Thanks in advance
    Regards
    Neha Kapoor

    hi neha ,
    1.first u have to get MBLNR from AUFM for that order
    2.Next u have to call FM
    <b>AC_DOCUMENT_RECORD</b>
    I_AWTYP                         MKPF--->Constant
    I_AWREF                         4900003215--->MBLNR
    I_AWORG                         2004--->Year
    I_AWSYS
    I_AWTYP_INCL
    I_AWTYP_EXCL
    I_BUKRS
    I_VALUTYP                       0
    X_DIALOG                           X
    then u will get the Accounting Documents.
    regards
    prabhu

  • Problem regarding the creation of Table using CSS.

    Hi ,
    Here I have a Problem regarding the creation of Table using CSS.
    In My Application i have a table with multiple rows(Rows are Dynamically added to the table).First i am setting the table with the following properties:
    width:900px;
    height : auto,
    Overflow : visible,
    Max-height: : 200px.
    If I use above properties,I'm getting a table with 5 or 6 rows(height upto 200px).After that i am getting the Vertical ScrollBar.
    The problem is when a table has many columns, Vertical and Horizontal Scrolls are coming at the time of setting the table. The table height is not Increasing dynamically.
    How can i use "height" property in CSS? (I want the table height to be increased when the columns are more.)
    Thanks & Regards
    Madhavi

    Hey humble user. Errr I'm trying to understand what ur trying to do. U want to create a section of a region destructively from an existing region right? If so select the option convert to new region (opt-comm-R or selecting it by right clicking). Check your audio bin to make sure. Whats the "merge" function? Are u refering to the glue tool?

  • Where to find the information regarding relationships between the tables?

    I am developing a Windows based app which among other things let’s users view SAP table schema and relationships.
    If I use SAP GUI and dig up a bit on say the MARA table I can see that
    Material Master (MARA) is related with
    1) MaterialDescription (MAKT) on columns MANDT and MATNR
    2) MaterialPlantData (MARC) on columns MANDT and MATNR
    and so on…
    My question is - in which table the information regarding relationships between the tables is stored? There must be a data dictionary table which would be storing the relationships data. Which is it? Note: I will programatically access the table, NOT from the UI.

    Thanks a lot...
    I am still working on it, but here are the current findings. DD05S, DD08L and DD08T: The schemas for these tables were very promising for the thing I was looking for. Unfortunately the data within dose not seem to serve my exact purpose.
    I found another one DD26S, which has almost 90% of the relationships I wish to explore. Do you know what is it supposed to contain?
    Thanks a lot for your help.
    Message was edited by: Salil Khedkar

  • URGETNT: REGARDING Purchase Requsition Approval tables

    hi,
    I am making a report on purchase requsition and i have to display the details of which person has approved it and its date of approval. can anybody tell me which are the tables used in it to display it,example :-
    1st Approval - Name of d person      Date of Approval
    2nd Approval - Name of d person     Date of Approval
    3rd  Approval - Name of d person     Date of Approval
    Final Approval - Name of d person    Date of Approval
    this type of details i want to display in my report. if anybody gives me tables and details about it to make d <b><b>report ,he or she will be definately REWARDED...
    Currently i am using table <b>EBAN,EBKN</b> ..
    Regards,
    Ric.s

    Use these table to see who released and description
    T16FC  -  Release code for particular release group
    T16FD  -  Description for Release code
    T16FG  -  Release Groups
    T16FH  -  Descriptions of Release Groups
    T16FK  -  Release Statuses
    use BAPI to get release information for PR .
    BAPI_REQUISITION_GETRELINFO.
    reward points if useful.
    Regards,
    Vimal
    Message was edited by:
            Vimal Kumar

  • Regarding index and anla table

    Hi
    i have code as below and i have Select option input
    for fields bukrs, anln1 and anln2.
    SELECT bukrs      anln1     anln2     anlkl txt50 ktogr invnrz sernr deakt               
        FROM anla                    
        INTO TABLE o_anla                    
       WHERE bukrs IN wa_ex_bukrs.
       if sy-subrc = 0.
       DELETE o_anla WHERE anln2 NOT IN wa_ex_anln2.
       DELETE o_anla WHERE anln1 NOT IN wa_ex_anln1.
       endif.
    Does the below code change is more faster than above code.?
    SELECT bukrs anln1 anln2 anlkl txt50 ktogr invnrz sernr deakt               
        FROM anla                    
        INTO TABLE o_anla                    
       WHERE bukrs IN wa_ex_bukrs
       and anln1 in wa_ex_anln1
       and anln2 in wa_ex_anln2.
    I feel bukrs and anln1 and anln2 are primary key fields and could increase performance better.
    However there is no std index available for this 3 fields. do you think creating secondary index
    for this 3 field can increase performance.
    Pls confirm.
    Regards

    Hi,
    If bukrs, anln1 and anln2 makes the primary key then you are hitting the table with primary index itself(which is always a better option for good performance). Your 2nd query would always do better.  No need to create secondary index in this case.
    Regards,
    Ravi

  • Regarding looping of a table

    how can we loop a table with respect to the index values of the table i want to loop the table upto an index 5 how can i do it.
    thanks in advance

    hi
    Sample Code:
    READ TABLE T_MARC1 INTO WA_MARC WITH KEY WERKS = P_WERKS.
    IF SY-SUBRC EQ 0.
    L_TABIX = SY-TABIX + 1.
    ADD 1 TO COUNT.
    LOOP AT T_MARC1 INTO WA_MARC FROM L_TABIX.
    IF WA_MARC-WERKS NE P_WERKS.
    EXIT.
    ENDIF.
    ADD 1 TO COUNT.
    ENDLOOP.
    ENDIF.
    If you look at the above code, first we read the record which appears first in the list of records, hence the index of that entry is stored in a local variable, further records can be read using index from loop which is very fast in access.
    regards
    Satish

  • Regarding Uploading of internal Table - Its Urgent.

    Hi All,
                 I want to upload the data from an Excel File into Interna Table.
                 GUI_UPLOAD is used for Flat File but for Excel Which FM should I use?
                 Can Any One give me the sample code for this ?
                 Points will be rewarded.   
                 Thanks in Advance.
    Regards
    Jitendra Gujarathi

    hi
    REPORT zupload_excel_to_it NO STANDARD PAGE HEADING.
    TYPES:   BEGIN OF t_datatab ,
             col1(25)  TYPE c,
             col2(30)  TYPE c,
             col3(30)  TYPE c,
             col4(30)  TYPE c,
             col5(30)  TYPE c,
             col6(30)  TYPE c,
             col7(30) TYPE c,
             col8(30)  TYPE c,
             col9(30)  TYPE c,
             col10(30)  TYPE c,
             col11(30)    TYPE c,
           END OF t_datatab.
    DATA: it_datatab TYPE STANDARD TABLE OF t_datatab INITIAL SIZE 0,
          wa_datatab TYPE t_datatab.
    DATA : gd_scol   TYPE i VALUE '1',
           gd_srow   TYPE i VALUE '1',
           gd_ecol   TYPE i VALUE '256',
           gd_erow   TYPE i VALUE '65536'.
    DATA: it_tab TYPE filetable,
          gd_subrc TYPE i.
    *Selection screen definition
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    PARAMETERS:  p_file LIKE rlgrap-filename
                   DEFAULT 'c:\test.xls' OBLIGATORY.   " File Name
    SELECTION-SCREEN END OF BLOCK b1.
    AT SELECTION-SCREEN
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
      REFRESH: it_tab.
      CALL METHOD cl_gui_frontend_services=>file_open_dialog
        EXPORTING
          window_title     = 'Select File'
          default_filename = '*.xls'
          multiselection   = ' '
        CHANGING
          file_table       = it_tab
          rc               = gd_subrc.
      LOOP AT it_tab INTO p_file.
       so_fpath-sign = 'I'.
       so_fpath-option = 'EQ'.
       append so_fpath.
      ENDLOOP.
    START-OF-SELECTION.
    START-OF-SELECTION.
      PERFORM upload_excel_file TABLES   it_datatab
                                 USING   p_file
                                         gd_scol
                                         gd_srow
                                         gd_ecol
                                         gd_erow.
    END-OF-SELECTION.
    END-OF-SELECTION.
      LOOP AT it_datatab INTO wa_datatab.
        WRITE:/ wa_datatab-col1,
                wa_datatab-col2,
                wa_datatab-col3,
                wa_datatab-col4,
                wa_datatab-col5,
                wa_datatab-col6,
                wa_datatab-col7,
                wa_datatab-col8,
                wa_datatab-col9,
                wa_datatab-col10,
                wa_datatab-col11.
      ENDLOOP.
    *&      Form  UPLOAD_EXCEL_FILE
          upload excel spreadsheet into internal table
         -->P_TABLE    Table to return excel data into
         -->P_FILE     file name and path
         -->P_SCOL     start column
         -->P_SROW     start row
         -->P_ECOL     end column
         -->P_EROW     end row
    FORM upload_excel_file TABLES   p_table
                           USING    p_file
                                    p_scol
                                    p_srow
                                    p_ecol
                                    p_erow.
      DATA : lt_intern TYPE  kcde_cells OCCURS 0 WITH HEADER LINE.
    Has the following format:
                Row number   | Colum Number   |   Value
         i.e.     1                 1             Name1
                  2                 1             Joe
      DATA : ld_index TYPE i.
      FIELD-SYMBOLS : .
    Note: Alternative function module - 'ALSM_EXCEL_TO_INTERNAL_TABLE'
      CALL FUNCTION 'KCD_EXCEL_OLE_TO_INT_CONVERT'
        EXPORTING
          filename                = p_file
          i_begin_col             = p_scol
          i_begin_row             = p_srow
          i_end_col               = p_ecol
          i_end_row               = p_erow
        TABLES
          intern                  = lt_intern
        EXCEPTIONS
          inconsistent_parameters = 1
          upload_ole              = 2
          OTHERS                  = 3.
      IF sy-subrc <> 0.
        FORMAT COLOR COL_BACKGROUND INTENSIFIED.
        WRITE:/ 'Error Uploading file'.
        EXIT.
      ENDIF.
      IF lt_intern[] IS INITIAL.
        FORMAT COLOR COL_BACKGROUND INTENSIFIED.
        WRITE:/ 'No Data Uploaded'.
        EXIT.
      ELSE.
        SORT lt_intern BY row col.
        LOOP AT lt_intern.
          MOVE lt_intern-col TO ld_index.
          ASSIGN COMPONENT ld_index OF STRUCTURE p_table TO <fs>.
          MOVE lt_intern-value TO .
          AT END OF row.
            APPEND p_table.
            CLEAR p_table.
          ENDAT.
        ENDLOOP.
      ENDIF.
    ENDFORM.                    "UPLOAD_EXCEL_FILE
    plz reward points!
    rgds

  • Regarding appending data in table type

    Hello Experts,
    Actually, I have one structure and in that I am using one table type .
    e.g. in the main structure, fields are as follows,
      po_number   po_line_item_no  gr_details
    here gr_details is table type having following fields.
      gr_number gr_qty gr_date
    As we all know that one po can have multiple GR,
    I want to append entries in the above structure in such a way that for one po entry , in the same record , multiple Gr entries should come.
    I am doing one program , in it is mendatory.
    can anyone please revert back on the same with High Priority ( Coding in Program to append values as per explained above ).
    Best Regards,
    Rashmi.

    Hi!
    For the same PO entry multiple GRs in same record is not possible. But you can have multiple GR entries in your internal table with same PO details.
    For eg. If you have one PO with 4 GRs then you will have 4 lines in internal table that belong to same PO but different GRs. In this case PO details would be redundant.
    To read these values into internal table
    1. You can read the GR details into corresponding columns of internal table and then update the PO columns for these records.
    2. The other bit diffcult way could be to read all PO details into internal table. Then loop at internal table for each PO find out the no. of GRs. If it has N no of GRs then add (N-1) rows with same PO details and different GR details and update the N the GR detail into the existing row of the internal table. If it has only 1 GR then update the existing line. If PO has no GR then delete the table line.
    Reward points for all the useful answers.

  • Regarding performance on cluster tables.vvv.urgent!

    friends,
      i know that cluster tables cannot be joined with transparent tables....
       however i need performance improvement for the following code....
       if possible is there a way to join bkpf or bseg to improve performance....can we create view foe bkpf and bseg if yes then how.....
      please modify the below code for improvement in performance.
      START-OF-SELECTION.
      SELECT bukrs belnr gjahr budat FROM bkpf INTO TABLE i_bkpf
      WHERE bukrs = p_bukrs AND "COMPANY CODE
              gjahr = p_gjahr AND "FISCAL YEAR
              budat IN s_budat. "POSTING DATE IN DOC
      IF sy-subrc = 0.
      SELECT bukrs belnr gjahr hkont shkzg dmbtr FROM bseg INTO TABLE
            i_bseg FOR ALL ENTRIES IN  i_bkpf
            WHERE bukrs = i_bkpf-bukrs AND "COMPANY CODE
                  belnr = i_bkpf-belnr AND "A/CING DOC NO
                  gjahr = i_bkpf-gjahr AND "FISCAL YEAR
                  hkont = p_hkont. "General Ledger Account"
        IF sy-subrc = 0.
         SELECT bukrs belnr gjahr hkont shkzg dmbtr FROM bseg INTO TABLE
                i_bseg1 FOR ALL ENTRIES IN  i_bseg
                WHERE bukrs = i_bseg-bukrs AND  "COMPANY CODE
                      belnr = i_bseg-belnr AND  "A/CING DOC NO
                      gjahr = i_bseg-gjahr.   "FISCAL YEAR
        ENDIF.
      ENDIF.
      IF NOT i_bseg1[] IS INITIAL.
        LOOP AT i_bseg1.
          IF i_bseg1-hkont = p_hkont AND i_bseg1-shkzg = 'S'.
            v_sumgl = v_sumgl + i_bseg1-dmbtr.
          ELSEIF i_bseg1-hkont = p_hkont AND i_bseg1-shkzg = 'H'.
            v_sumgl = v_sumgl - i_bseg1-dmbtr.
          ELSEIF i_bseg1-hkont NE p_hkont .
            IF i_bseg1-shkzg = 'H'.
              i_bseg1-dmbtr = - i_bseg1-dmbtr.
            ENDIF.
            i_alv-hkont = i_bseg1-hkont.
            i_alv-dmbtr = i_bseg1-dmbtr.
            APPEND i_alv.
            v_sumoffset = v_sumoffset + i_bseg1-dmbtr.
          ENDIF.
        ENDLOOP.
    regards
    Essam.([email protected])

    Hi there ...
    I have read the note - thats where I found the link to the trace note 286496.1 - on now to setup a trace
    But I still need an explanation for the methods (1,2,4 etc)
    regards
    Mette

  • Query regarding passivation and PS_TXN tables

    Hi All ,
    I am working on a read only Dashboard UI where the DB user has only read privileges.
    The jbo.server.internal_connection uses the same DB connection to create PS_TXN & PS_TXN_SEQ tables which fails for obvious reasons & I get the error -
    "Couldnot create persistence table PS_TXN_seq".
    I have disabled passivation at all the VO levels and also disabled jbo.isSupportsPassivation to be false at the AMLocal level , but still I am getting this error.
    I have also increased the initial AM pool size in bc4j.xcfg & Connection Pool at the weblogic server level to avoid snapshots been written to this table.
    Is there any way I can prevent any interaction with this table as the client too is not interested in any kind of passivation to happen for the time being.
    Thanks

    Thanks for your reply Chris.
    Chris Muir wrote:
    You might be taking the wrong approach to solving this. Rather than disabling the AM pooling (which btw is not supported by Oracle) to the database, instead you can get ADF to passivate to file or memory of the app server.I am confused as to what exactly jbo.ampool.issupportspassivation = false does then ? I read on one of the blogs that its a viable use case for Programatic VOs ?
    Also regarding passivating to file system as per http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/bcstatemgmt.htm#ADFFD1307 , its not really a recommended approach.. hence was not going for that.
    Can you please throw some more light ?
    Thanks

  • Regarding the SAP big tables in ECC 6.0

    Hi,
    We are having SAP ECC 6.0 running on Oracle 10.2g database. Please can anyone of you give fine details on the big tables as below. What are they? Where are they being used? Do they need to be so big? Can we clean them up?
    Table          Size
    TST03          220 GB
    COEP          125 GB
    SOFFCONT1      92 GB
    GLPCA          31 GB
    EDI40          18GB
    Thanks,
    Narendra

    Hello Narendra,
    TST03 merits special attention, certainly if it is the largest table in your database. TST03 contains the contents of spool requests and it often happens that at some time in the past there was a huge number of spool data in the system causing TST03 to inflate enormously. Even if this spool data was cleaned up later Oracle will not shrink the table automatically. It is perfectly possible that you have a 220 GB table containing virtually nothing.
    There are a lot of fancy scripts and procedures around to find out how much data is actually in the table, but personally I often use a quick-and-dirty check based on the current statistics.
    sqlplus /
    select (num_rows * avg_row_len)/(1024*1024) "MB IN USE" from dba_tables where table_name = 'TST03';
    This will produce a (rough) estimate of the amount of space actually taken up by rows in the table. If this is very far below 220 GB then the table is overinflated and you do best to reorganize it online with BRSPACE.
    As to the other tables: there are procedures for prevention, archiving and/or deletion for all of them. The best advice was given in an earlier response to your post, namely to use the SAP Database Management Guide.
    Regards,
    Mark

  • Extractor for AUFK and AFKO tables

    Hello Experts,
    I am looking for a standard extractor for the tables AUFK (Order Master data) and AFKO (Order Header). I wanted to know if there a exists a standard extractor for the same or I have to create a generic one.
    Thanks,
    Rishi

    For internal orders (ie aufk) have a look at 0COORDER and the transaction data  0CO_OM_OP*
    and the rest of the content for IOs
    http://help.sap.com/saphelp_nw70/helpdata/en/f2/db0c3c99d56448e10000000a114084/frameset.htm

Maybe you are looking for

  • [COVER FLOW BUG] Double albums in some circumstances

    I have found a bug affecting the Cover Flow feature. I have 2 Albums called "Greatest Hits" on my iPod Queen - Greatest Hits, and Venga Boys - Greatest Hits. If I open these albums using Cover Flow, a list of songs from both albums appear, instead of

  • A2107 Just got updated to 4.0.3

    Check your updates. This is available. So far, scrolling seems smoother. It's awesome to see Lenovo is updating our tablet. Here's hoping for Jelly Bean!

  • Downloading a .DAT file

    Am having a mental lapse here. Using DW MX 2004 on XP I need to create a link where a user (non computer literate) can download a .DAT file to his.her desktop. All i get is a "page cannot be found" error page Does the file has to be a .exe or .zip fi

  • Characters such as hearts and stars won't show up on Firefox

    I'm running on a Mac OS X 10.4.11 and my Firefox is 3.6.6. When I run all my other browsers (safari, opera) I'm able to see characters such as hearts and stars on a site like facebook. Only on firefox does it not show up, it doesn't even show boxes -

  • Which SSD is right for the X220?

    I'm planning on buying an OCZ SSD for my X220, but I'm not too familiar with the technical aspects of the SSD's. For example, I looked over their website and found things like SATA III, USB 3.0, mSATA, Max IOPS, and etc. I have no idea what most of t