Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Need a small information Relation between Bseg and Mseg.

former_member196331
Active Contributor
0 Kudos

Hi,

I need a small  information.May i know what is the relation between two child tables. Bseg and Mseg.

I can get record If i know Mseg table then

Mseg->Docnumer  = BKPF->AWKEY+YEAR.  Then

BKPF->DocEntry  = BSEG->Docentry.

But i need a link between .

MSEG->Linentry  == Bseg->Lineentry.

I Checked In forum. Financially i got no result. If there any possibility plz update me.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

hi,

here is the link between MSEG and BSEG

MSEG-WERKS  = BSEG-WERKS

MSEG-LIFNR = BSEG-LIFNR

MSEG-SAKTO = BSEG-HKONT     -

MSEG-EBELN =BSEG-EBELN

pass all these and you will get the unique line item.

First pass the BKPF header information to MSEG which you got in your link above.  then pass line item information plant, vendor, G/L account and PO#.

I tried in my system taking some sample data, it  gives the right information.

please let me know if this is sufficient.

4 REPLIES 4

VenkatRamesh_V
Active Contributor
0 Kudos

Hi,

MSEG:   Material Management       Module's movement  type Transaction  Details.

BSEG    Financial Management     Module  Transaction details.

eg:

Goods Inward  Transaction details are stored in MSEG table, Against the goods inward amount to be paid  are stored in BSEG table.

Hope it helpful,

Regards,

Venkat.

Former Member
0 Kudos

hi,

here is the link between MSEG and BSEG

MSEG-WERKS  = BSEG-WERKS

MSEG-LIFNR = BSEG-LIFNR

MSEG-SAKTO = BSEG-HKONT     -

MSEG-EBELN =BSEG-EBELN

pass all these and you will get the unique line item.

First pass the BKPF header information to MSEG which you got in your link above.  then pass line item information plant, vendor, G/L account and PO#.

I tried in my system taking some sample data, it  gives the right information.

please let me know if this is sufficient.

0 Kudos

HI, Av Thanks for your reply. Av

Thanks for your reply.  Gl account is not matching between mseg and bseg.

I checked two translations is ok, but second is not matching with other bseg line  items.

Bseg two lines are available one is debit and credit. It did not match with two lines items gl account

Mseg movment type is 201 .

My Requirement is i need to capture gl account from bseg.

Right now i am having , mseg line itmes and materials in my internal table.

But Bseg line items n number of i am having but

bseg->lineitem and mseg->i need to get.

My main task is capture gl account from bseg.

Can i get like this.

Under one BSEG~BELNR(I can get BELNR)

BSEG~MATERIAL = MSEG~MATERIAL.

BSEG~AMOUNT  = MSEG~AMOUNT.

raymond_giuseppi
Active Contributor
0 Kudos

As you have now learned there is no direct link between items of MSEG and BSEG and Customizing can even block copy of fields that would have been useful for reconciliation or summarize account lines so a n-n relation is possible)


But, AC interface also generated some 'work' tables as ACCTIT and ACCTCR that you could use to find not the BSEG item but the elements that generated it.


Hint: Look for OSS notes with keywords MSEG and BSEG and you should find some "corrective" notes that carry some report to correct BSEG from MSEG and vice-versa, e.g.  652242 - 525347: Correction Program for incorrect MSEG documents and similar notes, so analyze the attached programs.


Regards,

Raymond