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: 

BSIK and BSAK table fetching logic

Former Member
0 Kudos

Hi Gurus,

We have collected all invoices from BSIK and BSAK into an internal table now we want to fetch the purchase orders for the concerned invoices.

we have solution for that we are using BSEG which is a cluster table, as our requirement is not to fetch from Cluster tables, as it affects performance.

Can u please suggest a tranparent table and the selection criteria logic involved in that fetching

Advance Thanks,

Naveen.

5 REPLIES 5

Former Member
0 Kudos

Hi,

Retrieve data from EKKO/EKPO for the purchase orders obtained from BSIK/BSAK using for all entries of the same,

Rgds,

0 Kudos

Hi Sailatha Nagasamudram,

the fetching logic has flaw why becuase there is no common field fetching criteria in EKKO/EKPO ( fi document number we cannot get in EKKO and EKPO we require this document number)

Thanks,

Naveen

0 Kudos

Hi,

Check PO history table EKBE, you get the BELNR in this table, this can be mapped with BSIK/BSAK-BELNR,and get EBELN which is the Purchase document number,

Hope this helps,

Rgds,

Message was edited by: Sailatha Nagasamudram

0 Kudos

Purchasing Document Number(ebeln)

Former Member
0 Kudos

try to make use of this FM

l_awref = i_mblnr-->IR.

l_aworg = i_mjahr-->year.

l_awtyp = 'MKPF'.

call function 'AC_DOCUMENT_RECORD'

exporting

i_awtyp = l_awtyp

i_awref = l_awref

i_aworg = l_aworg

i_awsys = i_awsys

exceptions

no_reference = 1

no_document = 2

others = 3.

by using this u will get all accounting documents for all Invoicess which u can collect from EBKE for a given PO

Regards

prabhu