FIND Last Purchase Order of specific materials

Hello Gurus,
I wonder if someone can help to find the last purchase order created of certain materiales, which tables Do i have to search for?
thanks for the help.

Tables are EKPO (EKPO-MATNR for Material) then take all purchase order(EBELN) to search from table EKKO (EKKO-AEDAT for Date of creation)

Similar Messages

  • ME23N - Read Last Purchase Order for Display

    Hi,
    We are upgrading from 4.6C to ECC6 and one of the problems the users have identified is that when displaying the purchase order with transactions ME22N or ME23N the last purchase order that was worked on is not always the one that is displayed.
    This is very evident when creating a PO with ME21N and then switching to view it on ME23N - in ECC6 the PO that was created is never the PO that is displayed on ME23N; whereas in 4.6C creating a PO with ME21N and switching to ME23N the PO that was created is ALWAYS the PO that is displayed on ME23N.
    It this feature (whatever) no longer available with ECC6?  Is it a configuration settings that we haven't properly set in ECC6? 
    Thanks for any help.
    Martha

    I analysed how SAP remembers the previous purchase order number in transaction ME23N in version 4.7 as I do not have access to version ECC6. In version 4.7 transaction ME23N reads table ESDUS (MM: Dynamic User Settings) in the following way
    ESDUS-UNAME = sy-uname
    ESDUS-ACTION = 'MEPO'
    ESDUS-ELEMENT = 'Application         Po_Process'
    The purchase order number is the first 10 characters of ESDUS-ACTIVE (ESDUS-ACTIVE+0(10)).
    When you read a new purchase order SAP writes that order number to table ESDUS using function module ES_SAVE_USER_SETTINGS. When you revisit the transaction SAP uses function module ES_READ_USER_SETTINGS to read the purchase order number stored in table ESDUS.
    Ask an ABAP programmer to investigate this in your system with the information I have provided you. He/She should be able to find out what is going wrong. I am limited because I do not have access to your system. Hope this helps. Please let me know what the ABAP programmer found out.

  • Last purchase order price

    Hi All
    On which table will I be able to find the last purchase order price for a material
    Vishnu

    Hello, Vishnu
    Table name: EINE (Purchasing Info Record: Purchasing Organization Data)
    in the above table you can find the last PO price for that material. And the Conditions (Item) values are stored in the table: KONP (table name for Conditions (Item).
    Suggestion: The last PO document (i mean PO, which contains the price of the material in the PO line item) is updated in the Purchase Info record.(this you can see in the Info record display through t.code: ME13)
    Reward, if it helps,
    Regards,
    Srin.K
    Edited by: sapsrin on Feb 12, 2008 5:51 AM

  • Last Purchase Order & GRN Price

    HI,
    Anybody can tell me, inwhich table can able to find the Last Purchase Order Price and GRN price.
    Tks
    Mani.

    hi
    Table is EIPA.- order price history.
    Regards,
    Vijay

  • Last Purchase Order and FI-Document Number of an Vendor

    Hi,
    i need for an Vendor the last purchase Order and FI-Document Number.
    For purchase Order i read EKKO sort this and get the last one.
    For FI-Document Number i read BSIK and BSAK sort this and get last one.
    Question: is there any faster way (CLASS, FM or TABLE) to get what i need??
    Thanks.
    Regards, Dieter

    HI Dieter,
    You can use transaction code ME2L , where you can list of PO issued a particular vendor. List list shows Po no. indecending order. You can double click select the latest PO and through PO history you can get the FI Document no.
    I hope this ansers you query.
    Regards
    Harish

  • Excluding price of last purchase order from cost estimate

    Good morning,
    we have the issue described below:
    we would like to exclude a price of some purchase orders from valuation in cost estimate in case of valuation is made by price from purchasing info record.
    In this case valuation considers price of last purchase order even if there is a valid agreement used.
    Our customer would like to have valuation with price of purchasing agreement and not price of the standard purchase order closed, but if agreement is older and during creation of standard PO is setted the "InfoUpdate" flag, system updates the inforecord and in CK11N during cost calculation it uses this price for subcontracting.
    We have done some tests...Is there a standard SAP solution to have price of valid purchase agreement?
    Many thanks.
    Giusy Castiglione
    Accenture Outsourcing

    Hi,
    Your requirement seems to be very unique and hence you need to try out through by selecting the valuation through user exit where we can request the system take the po price from purchase agreement instead of purchase orders. This selection deftly resolve this unique requirement instead of searching for a std solution.
    Trust this helps much!
    Regards,!
    Ashok Singh

  • Last purchase order and goods receipt for material

    Hello to everyone,
    is there any standard report where I can see the last purchase order and goods receipt for a material?
    Regards

    Hi,
    Latest PO you can get from ME2M, by giving input as material and scope of list as best.
    Latest GR date can be get from MB51, by giving input as Material and movement type as 101.
    Regards,
    Prabu

  • Price from last purchase order

    Hi Experts,
    I have created info record xxx with some values for XX Vendor and XX Material. Then I have created PO with for same material and same vendor combination with different values and then I am creating PO for same material and same vendor combination but I am getting default price from info record values not last from PO Price. My client wants last PO price default at the time of PO creation.
    Pease advice me how can I solve this problem.
    Thanks in advance,
    Chandhu

    Hello
    You wered create the Info record means , system will have value PB00 in Inforecord. so when you create the PO then system fetch the PB00 value from Inforecord.
    The Last purchase order saved in Inforecord, but it will not fetch the last PO value for new PO.
    If you want to Last inforecord price in New PO, then do not create Inforecord for material and vendor combination,
    Ex: for fresh material and New vendor create PO, then system automaticaly creates the Inforecord in background,( At Purchase org level.)  then it save the last PO.
    When you try to create New PO for same combination then system will fetch the data from last PO.      here in PO  you will get PBXX ,instead of PB00.
    Regards
    Mahesh Naik.

  • Last goods receipt, last goods issue and last purchase order

    Hi Experts!!
    is there any table/info structure where I have the last goods receipt material document number, last goods issue material document number and last purchase order number? I want to extract this information to Business Warehouse.
    Best regards

    Are you looking for a report similar to MB51?
    If you put little more detail, i might be able to help. I don't know much about info structures but i can tell you the SAP tables.
    All Movement Details are in the below tables.
    MKPF- Material Document Header,
    MSEG - Material Document Detail -( you can put your material, plant for selection)
    Last PO  - you can get it from Info-record (EINE- EBELN, EINE-EBELP).
    Thanks,
    Shekhar Ramineni

  • I NEED TO FIND THE PURCHASE ORDER NO.

    HAI ALL,
         I NEED TO FIND THE PURCHASE ORDER NO.
    I have MATNR (material no.), LIFNR (vendor no.), RDOC OR MBLNR (material doc.no). values of these in my internal table. Using this i need to find purchase order no. I HAVE TRIED WITH MSEG TABLE ,but purchase order no. is not stored there.
    PL. tell me TABLE NAME OR HOW TO JOIN THA TABLES OR ANY VIEWS to find purchase order no.
    If u need any clarification regarding my req. pl send mail to below address.
    [email protected]
    THANKS IN ADVANCE,
    SENTHIL KUMAR

    HAI,
        THANKS FOR UR REPLY.
    I am using 541 movement type, (which is used for subcontracting)
    my req. is for 541 movement type in which table purchse order no. and mblnr(material doc. no.) are stored.
    Thanks in advance
    senthil kumar

  • How to find Specfic Purchase Order is being edited or not

    Hi Friends,
    How to find Specfic Purchase Order is being edited or not.
    Thanks in Advance.
    Murali Krishna K

    Hi ,
             When you are creating or editing a purchase order the table T160
    has a field TRTYP which keeps a track or edit or create or display.
    *     Masked
    A     Display
    B     Edit
    C     Display from archive
    E     Single-item planning
    H     Add
    V     Change
    X     Initial transaction
    S     Standard parameter: normal mode
    U     Convert indiv. planned order
    L     Delete
    P     Planning file entry
    K     Copy reference
    D     Print
    Please reward points if useful.

  • DMP ERROR When I am Finding the Purchase Order

    Hello Experts,
    I am Using SAP 8.8 PL 16
    My Client Finding the Purchase Order that time .DMP Error Creating.
    And Automatically SAP Application Doing Close
    Please Help me About that Issue
    Dixit Patel

    Hi Gordon
    I Created the New User  and Check with  that User
    Also Removing All File in Temp Folder
    But . DMP File is Creating
    Thanks
    Dixit Patel

  • How to find the Purchase Orders from Sales Order number

    Hi ...
    Is there a way to write a query to find the Purchase orders
    from the Sales Order number ....
    I have notice the table POR9 (Purchase Order - base Document)
    but it seems to be empty.
    Could you please help me to figure this out,
    Thank you very much
    Kind Regards
    Sanjaya

    hi,
                 u did mistake in selecting the table
    SELECT T0.DocNum FROM ORDR T0                 for  sales order
    SELECT T0.DocNum FROM OPOR T0                 for purchase order
    how to find the table in SAP B1.
    go to above menu view => system information. tick it(or select it)
    then below status bar u can see the table and field name.
    open the required form and just keep the  mouse cursor  on any field.
    you can see the table and field name below.
    hope now u can able to track the table name.
    regards
    sandip

  • Find Consignment Purchase Orders in EKKO / EKPO

    Hello all,
    have a following question: how can I find Consignment Purchase Orders in the tables EKKO or EKPO? Have tried but couldn't find the respective field...
    Thanks a lot and  best regards
    John

    Hi
    while creating Po we use item category K for consignment po
    so you should use K item category to serch your po In table EKPO
    Regards
    Kailas Ugale
    Edited by: kailasugale on May 4, 2011 6:11 PM

  • Last Purchase order of a material

    Hi All,
    I have a requirement to retrieve the last/latest purchase order for a given material/plant combination. Currently I am using the following logic. Here is the pseudo code I am using.
    Select EKPO records where MATNR = given material
                                                  WERKS = given material
                                                  BSTYP  = 'F'
                                                  LOEKZ  = space.
    select EKKO records where EKKO-EBELN = EKPO-EBELN.( for all EKPO records of unique EBELN)
    sort EKKO record by AEDAT DESCENDING.
    read table EKKO index 1.   "This is the record I need.
    This logic seems to be not good. As I am reading all the purchase orders of the material for entire period which will cause more database hit and memory issue. Say if we have maintained the system for 5 years and I am reading EKPO table for a material there will be more purchase orders for this material.
    Can you please suggest if there is a better logic to handle this?
    Regards,
    Srinivas.

    My approach will be to first speak with functional consultant to find what will be the most probable period in which you will find last PO for given material/plant.
    For example you might get an answer that you will find last PO of given/material within last week (or last month) for most of the combination.
    Once you get the period in which you will find the data, you can then construct logic as below
    date : r_date type range of ekko-aedat .
    fill range with last period (last week for example)
    DO .
    select field
      from ekko inner join ekpo on ekko~ebeln = ekpo~ebeln
    where ekko~BSTYP = 'F'
         and ekko~LOEKZ = space.
         and ekko~aedat in r_date
       and ekpo~werk = given plant
       and ekpo~matnr = given material
    if sy-subrc = 0 .
    * you got your record , sort and pick the right one
    * break the loop.
    else.
    **Check for exceptions
    * fill r_date with last to last period and so on...
    endif.
    ENDDO.
    Now about the exceptions, there might be some NOT SO ACTIVE material/plant for which last PO was create 3 years back (for argument sake). Again here you have to ask you functional consultant if he/she really want to see that old record or NOT SO ACTIVE material. If his/her answer is yes then he/she have to live with long execution time. Otherwise logic will be not to look beyond the time limit given by you functional consultant. For example, if you do not find PO in last 1 year then stop looking.
    Edited by: Pawan Kesari on Dec 11, 2009 10:35 PM
    Edited by: Pawan Kesari on Dec 11, 2009 10:37 PM

Maybe you are looking for