BSAK and EKBE tables...

Hello experts,
I am currently trying to modify a report where in it gets a PO's balance from BSAK-wrbtr but instead I need to get it from EKBE-wrbtr. So, is there a link between the 2 tables? Thanks guys and take care!

Hi Vijay,
You can check the link as Purchasing Document Number and Item Number of Purchasing Document:
BSAK-EBELN and BSAK-EBELP
in  EKBE-EBELN and EKBE-EBELP.
Then you ca retrieve EKBE-WRBTR.
Hope this may help you.
Regards,
Lanka

Similar Messages

  • Relation between BKPF and EKBE table for reversing document?

    Is there any relation between BKPF and EKBE table for reversing document when STBLG is blank in BKPF.
    AND
    How to differentiate Old Accounting document / Reverse document / New document when in BKPF-STBLG is blank for all three document and BKPF-XBLNR are same for all.

    Hi Varun,
    Table Document no (BKPF-BELNR) is link between Material document no (EKBE-BELNR). If you are looking for validating Material reversal document then please use following logic for your requirement.
    Material Document (MBLNR) & Material Document Year (MJAHR). Pass material document (MBLNR) to MSEG-SMBLN to read MSEG-MBLNR with MSEG-MJAHR to MSEG-SJAHR, if record found delete both the documents i.e. MSEG-SMBLN & MSEG-MBLNR (donu2019t consider these documents in the logic) and display Material Document No. (MSEG-MBLNR)
    Regards,
    Santosh

  • Delivery Number and EKBE table

    I have  a requirement to find out and print Delivery number all I have is PO number.
    and I was told that In EKBE if the PO history cat is "L" then fetch the Delivery Number.
    My question is from which table and which field i need to pull if the PO history category is L in EKBE table.
    Thanks in advance,,

    Here is the Link
    Get all the PO's From EKBE-BEWTP  " PO history cat is "L"
    Equal to 'L'.
    select * from ekbe
    into table it_ekbe
    where BEWTP = 'L'.
    if sy-subrc eq 0.
    select * from LIPS
       into table it_lip
       for all entries in it_ekbe
       where vgbel = it_ekbe-ebeln and
                vgpos = it_ekbe-ebelp.
    "This will give all the Deliveries realted to PO histort cat " L"
    endif.

  • How to link EKBE and MKPF tables

    HI all
    plz help me,
    how to link EKBE and MKPF tables
    thanks
    ramesh redddy

    HI,
    EKPO-EBELN =  EKKO-EBELN  has Purchase Documnet no.
    MSEG=MBLNR = MKPF-MBLNR  has material document no
    Link MSEG-EBELN =  EKPO-EBELN ( MSEG purchase prder no and EKPO purhcase document no.)
    and you should have to add one  more table MSEG which is provide three table.
    check this link
    EKPO-EBELN = EKKO-EBELN
    MSEG-EBELN =  EKPO-EBELN
    MSEG=MBLNR = MKPF-MBLNR
    regards,
    PK.

  • Problem LFPOS IN EKBE AND RSEG Tables

    HI!
      we have posted MIGO AND MIRO IN RSEG TABLE all the Item of a Reference Document are Updated Sequencely i.e, 1 - 20
    were as EKBE Table all the Item of a Reference Document  are Updated with 1 only no number sequence r updated as in RSEG Table.
    Kindly give a solution.
    Regards,
    Mohammed Rasul.S

    Hi Mohammed,
    LFPOS gives the number of the line item in a reference document as a GR or Invoice
    can have many line items related to the one PO. However the EKBE table does not
    need this type of field as it references the actual posting document, GR or invoice.
    Having such a field in EKBE would have a major impact on performance as when
    creating an invoice it has to go through the previous postings in EKBE to generate
    the necessary amounts for each transaction posting it creates in the follow on FI
    document.
    If you need to find the number of a document that was posted against a PO field BELNR
    in EKBE references the document number.
    Hope this helps,
    Adam.

  • PO number from EKBE Table

    Hi Experts,
    I want to prepare a new custom report in which the PO number should appear. I was advised to use EKBE table. On checking I found that I can pass only Material doc# and Fiscal Year and No company code field is found. Is it reliable to use only to input values and try to fetch the PO number? I am not sure if there could be more documents across company codes since the number range is set as company code level. Can you suggest any alternative?
    I have already searched for similar topic but could not find the correct answer.
    Please help.
    Thanks in advance.
    Sunil

    Hi Both,
    If I use MSEG table, I must use GR-MM document. As per my knowledge, IR document (MM/FI) won't reflect in MSEG table.
    If GR entry is done first, then I can fetch the AWKEY field from IR-FI doc to get the MM doc#. If the IR entry is done first, (without GR entry posted on PO line) then it is not very easy to fetch the GR-MM document number at a later point of time also.
    If the PO# is unique, independent from company code and year, then there are no issues, the below logic will work.
    Pass the IR-FI Document number to BKPF with BUKRS&GJAHR and take get IR-MM document (AWKEY - 10 +4). Then pass this to EKBE table with BELNR and GJAHR then pick the EBELN (PO#) and EBELP (line item).
    Please correct if I am not right.
    Thanks in advance!

  • SAP QUERY LOOPS AND INTERNAL TABLE

    Hi All, I have a query which i have made. It runs from Table EKPO which has PO details and what I want to do is now via ABAP Code pull through the total of goods receipt for the PO and Line Item into a field. Sounds Easy enough..Problem now,
    The table which contains the GR data is EKBE which agains a PO and Line Item can have many 101 movements and 102 movements so what I want is an ABAP Statent to basically sum up the total of 101 for the PO & LINE ITEMS and then minus this from the total of 102 for the PO & LINE ITEMS and post the result in to this new field I have created.
    I am pretty decent with ABAP Code in Querys I.e Select statements etc but from what I can see i need to create an internal table and do a loop and collect statement but I keep on failing due to not enough knowledge. Please can some one help me with this and provide me with the code and explanation as i would like to understand,
    POINTS WILL BE REWARDED
    Thanks
    Kind Regards
    Adeel Sarwar

    Hi,
    This is the full code i have entered but its not working. Any help would be appreciated. If you could rectify the code and internal tables that would be great.
    Thanks
    TABLES: EKBE.
    DATA: PurO LIKE EKPO-EBELN,
          POLI LIKE EKPO-EBELP.
    *New Table and Vars defined
    DATA:   BEGIN OF IT_EKBE,
              IT_EKBE LIKE EKBE,
            END OF IT_EKBE.
    DATA:  BEGIN OF IT_SUM OCCURS 0,
              EBELN TYPE EBELN,
              EBELP TYPE EBELP,
              DMBTR TYPE DMBTR,
              MENGE TYPE MENGE,
          END OF IT_SUM.
    CLEAR: QTYD.
    MOVE: EKPO-EBELN TO PurO,
          EKPO-EBELP TO POLI.
    SELECT * FROM EKBE INTO IT_EKBE
        WHERE EBELN = PurO
        AND   EBELP = POLI
        AND   BEWTP = 'E'
    LOOP AT IT_EKBE.
      MOVE CORRESPOING IT_EKBE TO IT_SUM.
      IF IT_EKBE-BWART = '102'.
        IT_SUM-DMBTR = IT_SUM-DMBTR * -1.
        IT_SUM-MENGE = IT_SUM-MENGE * -1.
      ENIDF.
      COLLECT IT_SUM.
      CLEAR IT_SUM.
    ENDLOOP.
    ENDSELECT.
    If sy-subrc = 0.
      QTYD = IT_SUM.
    ELSE.
      QTYD = 0.
    ENDIF.

  • Purchase order EKKN/EKBE tables

    Hi,
    I m creating a report based on purchase order. I'm getting sequence number from EKKN table and then getting the invoice details from EKBE table using where clause on EBELN, EBELP and ZEKKN(Seq number) fields.
    My question is in some cases in EKBE table, 00 seq number is populated, mostly for VGABE = 1 (Mat doc number) or VGABE= 9(Service entry sheet). But this 00 is not in EKKN table. So in that case i miss these invoices in my internal table, bcoz i'm querying based on seq number, and 00 is not there.
    Bcoz you cann't use 00 seq number at the time of PO creation.
    Can any body tell me how and in which senarios seq no (EKBE-ZEKKN) field is being populated, so that i can write the code accordingly....
    Thanks,

    Start your selection query from EKBE first and then go to EKKN based on the EBELN, EBELP & ZEKKN.
    Regards,
    Naimesh Patel

  • Qty field addtion based on item no. for ekbe table

    Hi experts,
                      below is my code..
    LOOP AT IT_EKKO.
      READ TABLE IT_LFA1 WITH KEY LIFNR = IT_EKKO-LIFNR.
       MOVE: IT_LFA1-NAME1 TO IT_DISPLAY-NAME1.
       MOVE: IT_EKKO-LIFNR TO IT_DISPLAY-LIFNR,
             IT_EKKO-AEDAT TO IT_DISPLAY-AEDAT,
             IT_EKKO-ERNAM TO IT_DISPLAY-ERNAM,
             IT_EKKO-EKGRP TO IT_DISPLAY-EKGRP.
    READ TABLE IT_EKPO WITH KEY EBELN = IT_EKKO-EBELN.
       MOVE: IT_EKPO-EBELN TO IT_DISPLAY-EBELN,
             IT_EKPO-MATNR TO IT_DISPLAY-MATNR,
             IT_EKPO-MENGE TO IT_DISPLAY-MENGE.
             LOOP AT IT_EKBE where ebeln eq it_ekko-ebeln.
                loop at it_ekbe." WHERE ebelp eq it_ekbe-ebelp.
             IT_DISPLAY-QTY = IT_DISPLAY-QTY + IT_EKBE-MENGE.
             AT END OF EBELP.
            APPEND IT_DISPLAY.
             CONTINUE.
             ENDAT.
             ENDLOOP.
             endloop.
             APPEND IT_DISPLAY.
             CLEAR IT_EKKO.
             ENDLOOP.
    my requirement is to display lifnr,ernam,ekgrp.....etc....
    but the condition is in ekbe table i hav to take purachse document no. from ekko table..based on this ebeln if suppose
    the item no. ebelp in ekbe has value say 10,10, den 20,20..for a single ebeln...then for same item no(10). the qty field should be added
    and for (20) item no. the qty field should be added.
    plz help...
    hw can i acheive this requirement.
    thanks n regards,
    Ashmita Singh.

    Hi Ashmita,
    Do the following changes in your program.
    Define it_lfa1 table as Hashed table with unique key on lifnr.
    Sort table it_ekpo before the loop start on ebeln and used binary search to read data from table.
    Define it_ekbe as sorted table with non-unique key on ebeln and EBELP use single loop.
    Write the following statement before main loop start. (ie it_ekko)
    delete ADJACENT DUPLICATES FROM it_ekbe COMPARING eblen EBELP.
    LOOP AT it_ekko.
    * Define it_lfa1 table as Hashed table with unique key
      READ TABLE it_lfa1 WITH KEY lifnr = it_ekko-lifnr.
      MOVE: it_lfa1-name1 TO it_display-name1.
      MOVE: it_ekko-lifnr TO it_display-lifnr,
      it_ekko-aedat TO it_display-aedat,
      it_ekko-ernam TO it_display-ernam,
      it_ekko-ekgrp TO it_display-ekgrp.
    * Sort table it_ekpo on ebeln and used binary search
      READ TABLE it_ekpo WITH KEY ebeln = it_ekko-ebeln.
      MOVE: it_ekpo-ebeln TO it_display-ebeln,
      it_ekpo-matnr TO it_display-matnr,
      it_ekpo-menge TO it_display-menge.
    * Define it_ekbe as sorted table with non unique key on ebeln and use single loop.
      LOOP AT it_ekbe WHERE ebeln EQ it_ekko-ebeln.
          it_display-qty = it_display-qty + it_ekbe-menge.
      ENDLOOP.
      APPEND it_display.
      CLEAR it_ekko.
    ENDLOOP.
    Kind Rgds
    Ravi Lanjewar

  • Generic DataSource by View on EKBE table.

    Hi All
    I am also trying to create View based on EKBE table . I am getting some errors even through  I have included at reference table ( EKBE,EKKO and T001)  with respective fields.
    View is Ok, only when I try to activate DataSource in  RSO2 , I am getting error like this
    Invalid extract structure template ZEKBE of DataSource ZPU_EKBE_FLEX1
    Message no. R8359
    Diagnosis
    You tried to generate an extract structure with the template structure ZEKBE. This operation failed, because the template structure quantity fields or currency fields, for example, field MENGE refer to a different table.
    Anybody had same issue ?
    Regards.
    E

    Hi Ram,
    Again Thanks for your reply.
    Like you said I have created everything from RSO2,  except View .
    I am not lucky yet. getting same error.
    Invalid extract structure template ZEKBE of DataSource ZEKBE
    Message no. R8359
    Diagnosis
    You tried to generate an extract structure with the template structure ZEKBE. This operation failed, because the template structure quantity fields or currency fields, for example, field MENGE refer to a different table.
    Kind regards.
    E

  • EKBE table for Generic Delta

    Hi Gurus,
    Good Day to all. I just like to inquire some details for creating generic datasource with delta enabled. I have created a view table with fields from EKBE table, and created generic datasource that reads the view table I have created from EKBE, now it needs delta process with CPUDT as delta specific field name, seeing the data type of CPUDT, it is DATS with 8 length.
    I would like to assure if what will be use as marker of delta, timestamp utc, timestamp local, calendar day and numeric pointer?
    And if I use one of the above, what settings that needs to be use for the safety interval upper and lower limit?
    Thank you for your inputs and really appreciate it.

    Hi,
    use the CALDAY as a generic delta pointer.
    i would like to recommend as: Safety Interval for Upper Limit as 1 and Safety Interval for lower Limit as ZERO
    i think your are using the DSO as a staging layer no worry about duplicates.
    Thanks,
    Phani.

  • Joining of cluster  and pooled tables ,transparent tables

    Hi,
    I wanted to do join between  cluster  ,pooled and transparent tables  but inner join won't allow  to join between  transparent or cluster tables or pooled tables .  The requirements are that join should take place dynamically  between transparent ,cluster ,pooled tables .I have written the Function module for joining multiple tables for transparent tables but unable to implement same for the transparent and cluster or pooled tables.How to handle the joining of tables between pooled or cluster  and transparent tables kindly provide me the answer .
    Thanks,
    jahnavi.

    Hi Jahnavi,
    My suggestion would be... if you want to retrieve the data between cluster tables and transparent tables.. its better to go for views instead of cluster tables then that would be easier for you to retrieve the data
    let us take one example BSEG its a cluster table where as there is one view VBSEGK it contains almost all the important fields needed so that u can make use of those or you can look into BSIK and BSAK tables so it better to avoid the cluster tables while retriving the data from the performance point of view

  • Business content referring RESB and MBEW tables for MM

    Hi Gurus,
    I have a requirement where i need to extract data from RESB and MBEW tables.
    Is there any business content extractor which takes data from these tables. or the data can be compensated from other tables like EKBE,EKKO,EKPO or MSEG. please let know. Help or advice is greatly appreciated. Thanks in advance.
    Regards,
    Satish

    You'll have to use 0CO_PC_ACT_05 (Material Valuation: Prices) for MBEW note that it doesn't support delta.
    For RESB you might look at 0PS_COMPONT_ATTR, but I'm not really shure
    Message was edited by:
            Pabloj

  • 2LIS_02_SCL - need Doc Currency Amount (WRBTR) from EKBE table

    Problem:  We are using the 2LIS_02_SCL to get our purchasing order data.  The problem is that instead of sending over the Doc Value Amounts found in the EKBE table, SAP is doing a calculation based on the the local currency.  They are then using the Exchange rate from the PO Header.  Our users are complaining, because they expect it to match up with what is in the purchase order history.
    I was planning to create a new amount field and and in my transfer rules write ABAP code to take the following fields from 2LIS_02_SCL:
    BW:CValLC(BWGEO), Local cur.(HWAER), Posting Date, Currency(WAERS)
    Use this Date to go back to TCURR to get the correct exchange rate that is used and do my calculation to doc currency (basically replicating the data as viewed in PO History).
    I ran into an issue however.  The Currency (WAERS) field is being filled with the value from EKKO.  I have a below example where in EKBE, the PO was invoiced in a currency other than the DOC Currency. 
    Data in R/3 from EKBE (History per PO)
    PO:                           1
    Amount in Local Currency(DMBTR):     250,01
    Local Currency (HSWAE):            USD
    Amount in Doc Currency(WRBTR):     250,01
    Doc Currency (WAERS):          USD
    Data in R/3 from EKKO (Purchase Order Header)
    PO:                         1
    WAERS:                    DKK
    In this scenario, I am unable to populate the correct value (as seen in purchase order history).
    I don’t see of a way that I can get around this.  Does anyone have any ideas?
    Thanks

    Hi Jiri,
    You can suggest the RRI from cube built on SCL report to cube built on EKBE based on PO.
    Also check if this can be solved by using a multi-cube on these 2 cubes.
    I have done a RRI when I was facing the same issue.
    Regards,
    Niraj

  • Use of EKBE table

    Hi,
    can any one please solve my questions.
    What type of data saved in EKBE table.
    and total number of entries in EKPO and EKBE are same?
    OR
    for all the entries in ekpo, are same header and item details exist in EKBE?
    points will be rewarded.
    Thanks in Advance,
    Eswar

    hi,
    EKBE table is used to give details of po history document.
    i.e it gives details like whether goods receipt is done or invoice is done for aparticular po.
    the total entries of ekbe and ekpo cannot be same.
    because ekpo stores data when po is created .but in ekbe diifferent records r maintained for gr and vre...
    reward points if hlpful.

Maybe you are looking for

  • How to connect an MTN usb rotator to an Apple MacBook Pro 13'3

    How do i go about connecting my Apple MacBook Pro 13'3 to the interent with an "Huawei Mobile Broadband E367 HSPA+ USB ROTATOR" on the MTN Network

  • Help updating from 10.5.8 to snow leopard

    I am having serious trouble updating my mac to snow leopard. I am currently running 10.5.8 and here is my hardware overview: Model Name:          MacBook Pro 15"   Model Identifier:          MacBookPro2,2   Processor Name:          Intel Core 2 Duo  

  • Reciever file adapter configuration for Deep structure

    Hi Experts,                  I have a idoc to file scenario in which i used a data type for file in below format: DT_Test -->Recordset(0.unbounded) >E21DPU1(0.unbounded) >field1 >field2 >E21DPU5(0.unbounded) >filed 3 >filed 4 >E21DP03(0.unbounded) >f

  • How to open dot-files as doc?

    Hello there, we have several company word-templates (extension dot) and we´re planing to access these templates via the Portal (file system repository with connect to the server). If I doubleclick the dot-file in the windows explorer, I receive a doc

  • Why the website looks different in different browsers?

    Hello, I coded my website in Dreamweaver CS4, and let it go: http://www.lidesign.cc The problem is that it looks fine in Firefox, Safari, Opera but when I opened it in Explorer 7, some line appeared after header and also there is no space between par