Skip to Content
author's profile photo
Former Member

how to get relationship between material document no and accounting documen

Hi Experts !!

I want to create a report displaying accounting document no and GL account no buy providing PO No and material document no (MIGO No).

I want a database table from where I can get material document no (MIGO No)(MBLNR/BELNR) and accounting document(BELNR) no both.Currently I am using

BSEG for getting HKONT,EBELN,BELNR

MSEG for getting MBLNR by using EBELN (P.O. NO)

BKPF for getting BUDAT.

the problem came with EBELN (P.O. NO) as repeated entries are there.

I am unable to write query for getting MBLNR and BELNR for same EBELN (P.O. NO).

Is there any table where MBLNR and BELNR are related to each other??????

Thanks in advance !!!!

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

5 Answers

  • Best Answer
    author's profile photo
    Former Member
    Posted on May 04, 2011 at 04:14 AM

    Hi Vikas ,

    As Harish told BKPF table as BKPF-AWTYP = MKPF and then you can split the AWKEY is a good option. I did this .

    Regards,

    Madhu.

    Add comment
    10|10000 characters needed characters exceeded

  • author's profile photo
    Former Member
    Posted on May 04, 2011 at 06:09 PM

    Check this thread, if this helps.

    [url] Link between MKPF table and EKKO or RBKP table [url]

    I've done this as well earlier to create a custom document flow for archived documents where from the EBELN i've found all the related documents. Hope this helps.

    Add comment
    10|10000 characters needed characters exceeded

  • author's profile photo
    Former Member
    Posted on Apr 25, 2011 at 05:18 PM

    Please see [Quickly Retrieving FI document Data from BSEG|/people/rob.burbank/blog/2007/11/12/quickly-retrieving-fi-document-data-from-bseg]

    There is a section there that describes how to do exactly what you are trying to do.

    Rob

    Add comment
    10|10000 characters needed characters exceeded

  • author's profile photo
    Former Member
    Posted on Apr 26, 2011 at 12:37 PM

    Hi,

    You can use EKBE table to get both doc. there is a field PO history category trace material document(E) or invoice document number (Q).

    Add comment
    10|10000 characters needed characters exceeded

  • author's profile photo
    Former Member
    Posted on Apr 29, 2011 at 09:48 AM

    Hi,

    Try using the the BKPF table as BKPF-AWTYP = MKPF and then you can split the AWKEY field to get the material doc number details.

    Thanks & Regards,

    Harish

    Edited by: harishkumar.d on Apr 29, 2011 11:50 AM

    Add comment
    10|10000 characters needed characters exceeded