Expiring Lot-Controlled items and open orders/deliveries

<h5> Hi,
We are writing a custom program to block lot-controlled items which are near expiry. The custom program query LQUA-VERME (available stock) field to determine the qty it can block. However, the LQUA-VERME field does not take open orders and open deliveries into consideration. For example, for an item, the available stock in the warehouse (LQUA-VERME) is 20. But there are 5 open deliveries and 5 open sales orders. So in reality, the custom program should block only 10 units. Is there a SD table/field which has consolidated open deliveries and open orders qty we can look at? Or available stock in WM after considering open deliveries and open orders? <h5>
Thank you.

Hi,
SAP does availability check based on IM stock and not on WM stock.
So I dont think there are any such reports available that shows WM stock with considering delivery and sales order quantity.
regards,

Similar Messages

  • 11.5.10 ROI를 통해 SERIAL AND LOT CONTROLLED ITEMS을 처리하는 방법

    제품: Applications
    작성날짜 : 2006-05-30
    11.5.10 ROI를 통해 SERIAL AND LOT CONTROLLED ITEMS을 처리하는 방법
    ========================================================
    PURPOSE
    11.5.10 Receiving Open Interface(ROI)를 통해 Serial and Lot Controlled Items을 처리하기 위해 어떤 interface table들이 사용되는지에 대해 기술함.
    Explanation
    the Receiving Open Interface (ROI)를 통해 Serial and Lot Controlled Items에 대한 Delivery, Correction, Return등의 process를 수행하기 위해서는 다음 table들에 data가 존재하여야 합니다.
    - rcv_headers_interface
    - rcv_transactions_interface
    - mtl_transaction_lots_interface
    - mtl_transaction_serial_numbers_interface
    <참고>
    이와 같은 기능은 11.5.10/11i.SCM_PF.J/11i.PRC_PF.J 에서 제공되는 신기능으로써 이전 version으로의 backport는 불가능합니다.
    Example
    1) If Item is Serial Controlled only:
    INSERT INTO MTL_SERIAL_NUMBERS_INTERFACE (
    TRANSACTION_INTERFACE_ID,
    LAST_UPDATE_DATE,
    LAST_UPDATED_BY,
    CREATION_DATE,
    CREATED_BY,
    LAST_UPDATE_LOGIN,
    FM_SERIAL_NUMBER,
    TO_SERIAL_NUMBER,
    PRODUCT_CODE,
    PRODUCT_TRANSACTION_ID) --link to rcv_transactions_interface
    VALUES
    (MTL_MATERIAL_TRANSACTIONS_S.NEXTVAL,
    sysdate,
    1,
    sysdate,
    1,
    1,
    'sr000016',
    'sr000016',
    'RCV',
    RCV_TRANSACTIONS_INTERFACE_S.CURRVAL); --same as
    rcv_transactions_interface.interface_transaction_id
    2) If Item is Lot Controlled only:
    INSERT INTO MTL_TRANSACTION_LOTS_INTERFACE (
    TRANSACTION_INTERFACE_ID,
    LAST_UPDATE_DATE,
    LAST_UPDATED_BY,
    CREATION_DATE,
    CREATED_BY,
    LAST_UPDATE_LOGIN,
    LOT_NUMBER,
    TRANSACTION_QUANTITY,
    PRIMARY_QUANTITY,
    PRODUCT_CODE,
    PRODUCT_TRANSACTION_ID) --link to rcv_transactions_interface
    VALUES
    (MTL_MATERIAL_TRANSACTIONS_S.NEXTVAL,
    sysdate,
    1,
    sysdate,
    1,
    1,
    'lt2002',
    1,
    1,
    'RCV',
    RCV_TRANSACTIONS_INTERFACE_S.CURRVAL); --same as
    rcv_transactions_interface.interface_transaction_id
    3) If Item is both Serial and Lot Controlled:
    INSERT INTO MTL_SERIAL_NUMBERS_INTERFACE (
    TRANSACTION_INTERFACE_ID,
    LAST_UPDATE_DATE,
    LAST_UPDATED_BY,
    CREATION_DATE,
    CREATED_BY,
    LAST_UPDATE_LOGIN,
    FM_SERIAL_NUMBER,
    TO_SERIAL_NUMBER,
    PRODUCT_CODE,
    PRODUCT_TRANSACTION_ID) --link to rcv_transactions_interface
    VALUES
    (MTL_MATERIAL_TRANSACTIONS_S.NEXTVAL,
    sysdate,
    1,
    sysdate,
    1,
    1,
    'sr000016',
    'sr000016',
    'RCV',
    RCV_TRANSACTIONS_INTERFACE_S.CURRVAL); --same as
    rcv_transactions_interface.interface_transaction_id
    INSERT INTO MTL_TRANSACTION_LOTS_INTERFACE (
    TRANSACTION_INTERFACE_ID,
    LAST_UPDATE_DATE,
    LAST_UPDATED_BY,
    CREATION_DATE,
    CREATED_BY,
    LAST_UPDATE_LOGIN,
    LOT_NUMBER,
    TRANSACTION_QUANTITY,
    PRIMARY_QUANTITY,
    SERIAL_TRANSACTION_TEMP_ID, --link to mtl_serial_numbers_interface
    PRODUCT_CODE,
    PRODUCT_TRANSACTION_ID) --link to rcv_transactions_interface
    VALUES
    (MTL_MATERIAL_TRANSACTIONS_S.NEXTVAL,
    sysdate,
    1,
    sysdate,
    1,
    1,
    'lt2002',
    1,
    1,
    MTL_MATERIAL_TRANSACTIONS_S.CURRVAL, --link to mtl_serial_numbers_interface
    'RCV',
    RCV_TRANSACTIONS_INTERFACE_S.CURRVAL); --same as
    rcv_transactions_interface.interface_transaction_id
    Reference Documents
    Note#301281.1

    hi
    enable Readahead from systemd
    https://wiki.archlinux.org/index.php/Systemd#Readahead
    # systemctl enable systemd-readahead-collect systemd-readahead-replay

  • Consignment stock - consumption advice for lot controlled item

    Consignment stock - consumption advice for lot controlled item
    Just have a look at consignment stock processing in 11.5.10. One question I have is how a supplier receives a consumption advice. I try to print the blanket release and I cant. Also from all I can see I cant see where on the consumption advice the lot numbers/serial numbers used are indicated.
    Can anyone help?

    Hi,
    SAP does availability check based on IM stock and not on WM stock.
    So I dont think there are any such reports available that shows WM stock with considering delivery and sales order quantity.
    regards,

  • Issue in lot controlled items reservation API

    Hi,
    When I am going to reserved the lot controlled item thru following API, it is giving an error message.  Can anyone help me to resolve this issue as it is not showing an detail error message .
    Following is the Error message :
    =======================================================
    Calling INV_RESERVATION_PUB.Create_Reservation API
    =======================================================
    Return Status: E-INV
    Error Message :INV
    =======================================================
    Following API we are using for the same:
    DECLARE
            -- Common Declarations
            l_api_version         NUMBER      := 1.0;
            l_init_msg_list       VARCHAR2(2) := FND_API.G_TRUE;
            x_return_status       VARCHAR2(2);
            x_msg_count           NUMBER      := 0;
            x_msg_data            VARCHAR2(255);
            l_row_cnt        NUMBER := 1;
            -- API specific declarations
            l_rsv_rec                   INV_RESERVATION_GLOBAL.MTL_RESERVATION_REC_TYPE;
            l_serial_number             INV_RESERVATION_GLOBAL.SERIAL_NUMBER_TBL_TYPE;  
            l_partial_reservation_flag  VARCHAR2(2) := FND_API.G_FALSE;
            l_force_reservation_flag    VARCHAR2(2) := FND_API.G_FALSE;
            l_validation_flag           VARCHAR2(2) := FND_API.G_TRUE; 
            l_partial_reservation_exists BOOLEAN := FALSE;       
            x_serial_number             INV_RESERVATION_GLOBAL.SERIAL_NUMBER_TBL_TYPE;
            x_quantity_reserved         NUMBER := 0;
            x_reservation_id            NUMBER := 0;
    BEGIN
            FND_GLOBAL.APPS_INITIALIZE(  user_id      => 5707,
                                         resp_id      => 50158,
                                         resp_appl_id => 401);
            -- Initialize the variables
                  l_rsv_rec.organization_id               :=   51; --NULL; --itm.organization_id;
                  l_rsv_rec.inventory_item_id             :=   52587;--NULL; --itm.inventory_item_id;
                  l_rsv_rec.requirement_date              :=   NULL; --sysdate + 3;
                  l_rsv_rec.demand_source_type_id         :=   INV_RESERVATION_GLOBAL.G_SOURCE_TYPE_INV;
                  l_rsv_rec.supply_source_type_id         :=   INV_RESERVATION_GLOBAL.G_SOURCE_TYPE_INV;
                  l_rsv_rec.demand_source_name            :=   NULL; --'RSV_ITM_SRL_'||itm.segment1;
                  l_rsv_rec.primary_reservation_quantity  :=   100; --NULL; --l_primary_reservation_qty;
                  l_rsv_rec.primary_uom_code              :=   'MTR'; --NULL; --itm.primary_uom_code;
                  l_rsv_rec.subinventory_code             :=   NULL; --l_subinventory_code;
                  l_rsv_rec.demand_source_header_id       :=   306842; --NULL ;
                  l_rsv_rec.demand_source_line_id         :=   2288893; --NULL ;        
                  l_rsv_rec.reservation_uom_code          :=   'MTR' ;
                  l_rsv_rec.reservation_quantity          :=   100; --NULL ;
                  l_rsv_rec.supply_source_header_id       :=   NULL ;
                  l_rsv_rec.supply_source_line_id         :=   NULL ;
                  l_rsv_rec.supply_source_name            :=   NULL ;
                  l_rsv_rec.supply_source_line_detail     :=   NULL ;
                  l_rsv_rec.lot_number                    :=   'ABC100'; --NULL ;
                  --l_rsv_rec.serial_number                 :=   NULL ;
                  l_rsv_rec.ship_ready_flag               :=   NULL ;
                  l_rsv_rec.attribute15                   :=   NULL ;
                  l_rsv_rec.attribute14                   :=   NULL ;       
                  l_rsv_rec.attribute13                   :=   NULL ;
                  l_rsv_rec.attribute12                   :=   NULL ;
                  l_rsv_rec.attribute11                   :=   NULL ; 
                  l_rsv_rec.attribute10                   :=   NULL ;
                  l_rsv_rec.attribute9                    :=   NULL ;     
                  l_rsv_rec.attribute8                    :=   NULL ; 
                  l_rsv_rec.attribute7                    :=   NULL ;
                  l_rsv_rec.attribute6                    :=   NULL ; 
                  l_rsv_rec.attribute5                    :=   NULL ;      
                  l_rsv_rec.attribute4                    :=   NULL ;  
                  l_rsv_rec.attribute3                    :=   NULL ;
                  l_rsv_rec.attribute2                    :=   NULL ;  
                  l_rsv_rec.attribute1                    :=   NULL ;  
                  l_rsv_rec.attribute_category            :=   NULL ;
                  l_rsv_rec.lpn_id                        :=   NULL ;
                  l_rsv_rec.pick_slip_number              :=   NULL ;
                  l_rsv_rec.lot_number_id                 :=   NULL ;
                  l_rsv_rec.locator_id                    :=   NULL ;
                  l_rsv_rec.subinventory_id               :=   NULL ;
                  l_rsv_rec.revision                      :=   NULL ;
                  l_rsv_rec.external_source_line_id       :=   NULL ;     
                  l_rsv_rec.external_source_code          :=   NULL ;     
                  l_rsv_rec.autodetail_group_id           :=   NULL ;    
                  l_rsv_rec.reservation_uom_id            :=   NULL ;    
                  l_rsv_rec.primary_uom_id                :=   NULL ;   
                  l_rsv_rec.demand_source_delivery        :=   NULL ; 
                  -- call API to create reservation
                 DBMS_OUTPUT.PUT_LINE('=======================================================');
                 DBMS_OUTPUT.PUT_LINE('Calling INV_RESERVATION_PUB.Create_Reservation API');       
                 INV_RESERVATION_PUB.Create_Reservation(
                          P_API_VERSION_NUMBER     => l_api_version  
                        , P_INIT_MSG_LST         => l_init_msg_list
                        , P_RSV_REC             => l_rsv_rec           
                        , P_SERIAL_NUMBER         => l_serial_number           
                        , P_PARTIAL_RESERVATION_FLAG => l_partial_reservation_flag
                        , P_FORCE_RESERVATION_FLAG     => l_force_reservation_flag  
                        , P_PARTIAL_RSV_EXISTS     => l_partial_reservation_exists
                        , P_VALIDATION_FLAG         => l_validation_flag     
                        , X_SERIAL_NUMBER         => x_serial_number             
                        , X_RETURN_STATUS         => x_return_status
                        , X_MSG_COUNT         => x_msg_count   
                        , X_MSG_DATA              => x_msg_data              
                        , X_QUANTITY_RESERVED     => x_quantity_reserved
                        , X_RESERVATION_ID         => x_reservation_id);           
                 DBMS_OUTPUT.PUT_LINE('=======================================================');
                 DBMS_OUTPUT.PUT_LINE('Return Status: '||x_return_status||'-'||x_msg_data);
                 IF (x_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
                    DBMS_OUTPUT.PUT_LINE('Error Message :'||x_msg_data);
                 END IF;
                 IF (x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
                     DBMS_OUTPUT.PUT_LINE('Reservation ID :'||x_reservation_id||' Quantity Reserved:'||x_quantity_reserved);
                     COMMIT;
                 END IF;
                 DBMS_OUTPUT.PUT_LINE('=======================================================');
    EXCEPTION
            WHEN OTHERS THEN
              DBMS_OUTPUT.PUT_LINE('Exception Occured :');
              DBMS_OUTPUT.PUT_LINE(SQLCODE ||':'||SQLERRM);
              DBMS_OUTPUT.PUT_LINE('=======================================================');
    END;
    regards & thanks in advance
    sanjay

    Hi,
    SAP does availability check based on IM stock and not on WM stock.
    So I dont think there are any such reports available that shows WM stock with considering delivery and sales order quantity.
    regards,

  • Need to Stop Serial/Lot control item to be automatically picked

    Hi,
    I have an requirement for auto (schedule pick release). But customer wants that only non serial/lot controlled items will be auto picked. But Lot Controlled and Serial Controlled (At Receipt) items will not be picked automatically. How I can achieved that ?
    Thanks for your help.
    Regards,
    Amit

    Hi Sayantan,
    You do have a couple of options depending on what release of the apps you're on and how you set the Inv Org parameter Allocate Serial Numbers.
    From 11.5.10 on, a potential new value can be set for this parameter (available also on 11.5.8 and 9 via backport patch). The parameter governs the way serial numbers are allocated at Pick Release.
    Previously, the values available for this parameter were just a basic “No” (the default value) or “Yes” (whereby Oracle would auto-suggest, in a non-intelligent way, available serial numbers at the time of pick release). The new value available is “Yes – User-defined” which allows some custom logic to be applied to the serial number allocation.
    With the value set to “Yes – User-defined”, Oracle checks for any custom code in the INVSRSTB.pls stub/custom hook when a pick release is launched. (Inv_Detail_Serial_Pub.Get_User_Serial_Numbers)
    Regards,
    Jon
    P.S. Also take a look at *Auto Pick Confirm Flag Does Not Work For Serial Items If Allocate Serial Number is Set to'Yes User Defeined' [ID 337964.1]* on MOS.

  • Programatically create new mail item and open - body text lost on subsequent saves

    Hi,
    I have a problem with trying to create new GroupWise mail item from a
    button in a C3PO. I require programmatic access to this via the Object
    API, so it must be a saved draft. This is relativley straight forward to
    do - just create a mail item using the object API, and then use the Token
    API to open this item.
    This worked fine in 6.5.0, however in 6.5.1 and 6.5.2 I have noticed that
    when the user does a subsequent save, the body text of the message
    dissappears in the GUI (it is updated correctly in the draft however) -
    and all subsequent saves cause the body text to dissappear. If you close
    the mail item and open the draft manually you can continue as normal.
    As a test, I also tried to use the Token API to create a new mail item,
    and then again to save the item in the work in progress folder. This
    seems to work fine the very first time you do this, but each subsequent
    time the same behaviour is seen - i.e. the body text of the email is
    deleted from the GUI. Also, another observation here, event though the
    mail item was saved in the WIP folder via the token API command
    ItemSaveMessageDraft, it moves into the users MailBox when the user saves
    it manually.
    I have posted the two snippets of code from my test C3PO project at then
    end.
    This is a major problem, as we need to be able to reliably create new mail
    items from a toolbar button, so any help very much appreciated.
    Regards
    Greg
    Test case 1: Create a new message object in the WIP folder, and then open
    it using Token API...
    Dim sRetString As String
    Dim DraftMail As Object
    Set DraftMail =
    g_C3POManager.ClientState.CurrentAccount.WorkFolde r.Messages.Add
    ("GW.MESSAGE.MAIL", egwDraft)
    g_Commander.Execute "ItemOpen(""" & DraftMail.MessageId & """)", sRetString
    Test case 2: Create a new mail via token API, then use token API to save
    the item in the WIP folder...
    Dim sRetString As String
    ' create the new mail item...
    g_Commander.Execute "NewMail()", sRetString
    ' Get the folder path as a string..
    Dim GWFolder As Object
    Dim sAccount As String
    Dim sFolderPath As String
    sAccount = g_C3POManager.ClientState.CurrentAccount.RootFolde r.Name
    Set GWFolder = g_C3POManager.ClientState.CurrentAccount.WorkFolde r
    sFolderPath = sAccount & "\" & GWFolder.Name
    ' dirty the message so save works...
    g_Commander.Execute "ItemSetText(""X00"";Subject!;"" "")", sRetString
    g_Commander.Execute "ItemSetText(""X00"";Subject!;"""")", sRetString
    ' do the save...
    g_Commander.Execute "ItemSaveMessageDraft(""" & sFolderPath & """)",
    sRetString

    Hi,
    I have a problem with trying to create new GroupWise mail item from a
    button in a C3PO. I require programmatic access to this via the Object
    API, so it must be a saved draft. This is relativley straight forward to
    do - just create a mail item using the object API, and then use the Token
    API to open this item.
    This worked fine in 6.5.0, however in 6.5.1 and 6.5.2 I have noticed that
    when the user does a subsequent save, the body text of the message
    dissappears in the GUI (it is updated correctly in the draft however) -
    and all subsequent saves cause the body text to dissappear. If you close
    the mail item and open the draft manually you can continue as normal.
    As a test, I also tried to use the Token API to create a new mail item,
    and then again to save the item in the work in progress folder. This
    seems to work fine the very first time you do this, but each subsequent
    time the same behaviour is seen - i.e. the body text of the email is
    deleted from the GUI. Also, another observation here, event though the
    mail item was saved in the WIP folder via the token API command
    ItemSaveMessageDraft, it moves into the users MailBox when the user saves
    it manually.
    I have posted the two snippets of code from my test C3PO project at then
    end.
    This is a major problem, as we need to be able to reliably create new mail
    items from a toolbar button, so any help very much appreciated.
    Regards
    Greg
    Test case 1: Create a new message object in the WIP folder, and then open
    it using Token API...
    Dim sRetString As String
    Dim DraftMail As Object
    Set DraftMail =
    g_C3POManager.ClientState.CurrentAccount.WorkFolde r.Messages.Add
    ("GW.MESSAGE.MAIL", egwDraft)
    g_Commander.Execute "ItemOpen(""" & DraftMail.MessageId & """)", sRetString
    Test case 2: Create a new mail via token API, then use token API to save
    the item in the WIP folder...
    Dim sRetString As String
    ' create the new mail item...
    g_Commander.Execute "NewMail()", sRetString
    ' Get the folder path as a string..
    Dim GWFolder As Object
    Dim sAccount As String
    Dim sFolderPath As String
    sAccount = g_C3POManager.ClientState.CurrentAccount.RootFolde r.Name
    Set GWFolder = g_C3POManager.ClientState.CurrentAccount.WorkFolde r
    sFolderPath = sAccount & "\" & GWFolder.Name
    ' dirty the message so save works...
    g_Commander.Execute "ItemSetText(""X00"";Subject!;"" "")", sRetString
    g_Commander.Execute "ItemSetText(""X00"";Subject!;"""")", sRetString
    ' do the save...
    g_Commander.Execute "ItemSaveMessageDraft(""" & sFolderPath & """)",
    sRetString

  • Reg: Lot control items

    Hi,
    Maximum all items are lot control, Assume for example: Item A as two lots, i am making a sub-inventory, for one lot i can manually select from lot field but for another lot i have to goto the lot/serial button and select lot .no and quantities then click on done.Finally save. If i am going to normal lot tab and selecting the lot, it is showing as this lot number is in use-but if i select lot/serial it is working fine. What would be the problem, can one suggest me.
    Regards
    SP

    If I understood you correctly, you are saying the below
    The Lot LOV on the Subinventory Transaction Form is NOT SAME as the Lot LOV on the Lot/Serial serial screen which opens on the click of Lot/Serial button.
    I asssume that the source subinv and locator values are the same when you are looking at both the LOV's, please confirm.

  • Open orders,deliveries,

    Hi
    SD Gurus,
    how to find out the open orders, opend deliveries and open billing documents plse explain on this
    regards,
    RAMU.G

    Hi
    Open Enquiries - VA15
    Open Quotations - VA25
    Open Sales Order - VA05
    Open Deliveries - VL05
    Oen Billing Docs - Vf05
    Open Inv Lists - VF25
    SE16 - TAble VBBE for open documents
    Regards

  • How to create service items and sales order for service contracts.

    Hi,
    I have created item using Purchased Item template and one more item(service item) using service /warranty program template. Then I have used these items to create sales order with service item in it and closed that order , but Iam not getting this order in service contracts. Is this right way to create sales order for service items. I
    item name:- personal_computer
    copied from purchased order template. service is enabled and install base is checked and enable service coverage is enabled.
    item name:- service_item
    copied from service /warranty program template
    service is selected to inactive,
    service type: service
    duration: 1 year
    template: Gold
    and saved the item.
    Then I have used these two items in sales order for service contracts. But that sales order is not hitting in service contracts. Is there any error with item creation.
    Thanks,
    Bharat G.

    Following SAP Notes to be referred for Service Tax:
    1.     778976 u2013 Service Tax and Ecess on Service Tax
    2.     1032265 - SEcess on Service Tax
    Regards
    AK

  • Liquidity Report not picking up Noted item and Sales orders

    Hi Experts,
    I created planning levels from source as PSK, yet the liquidity is not picking up these items from sales orders and purchase orders. Also while creating noted items, i have given planning levels in the configurarion and the same is not picking up in the liquidity too
    Please advice
    Thanks in Advance

    Hi Hien,
    We have created planning levels separately for MM and SD and we have created under SDF and MMF respectively.
    IT is working for group created for direct FI entrly and linked the same with PSK and the same is working fine.
    I am new to FSCM. Can you please elaborate FDFD?
    Thanks and Regards

  • [Tree] item and node order ! (Recursive Node)

    I made a wd4a has organizatonal structure tree. but I have some problem with the org tree.
    I want to have a tree(org structure) in item(person) and node(organization) order.
    Root                                            Root
      |- Person 1                                    |- Head Dept
      |- Person 2                                    |        |-Person 3
      |-Head Dept                        ->        |        |-Person 4
      |       |- Person 3                             |-Sales
      |       |- Person 4                             |- Person 1
      |-Sales                                          |- Person 2
    ( to be displayed)                                 (current displayed)
    Whiat's the problem?
    Although the both of them have a same contents, I really want to display in person and org order .
    Plz. help.

    I solved this problem myself and it makes me very so tired.
    I guess that Recursive node tree have some bugs.
    If a node have one recursive node and one sub-node and some kinds of attributes,
    we have to make a decision on how to display and sort them(sub-node and attributes)
    There is a example below as I really want to sort them.
      C_Drive Folder
    - file 1
    - file 2
    - Folder 1
    - file3
    - Folder 1-1
    - Folder 2
    Context
        |-Folder Node
        |      |-File Node
        |      |       |-File Name attribute
        |      |-Folder Name attribute
        |      |-Folder_Content             -> Recursive Node
    When you meet this situation,you must implement the context nodes and
    the names of context node and recursive node must be in alphabet order you want to display.
    I am sorry for my crumsy writting English.

  • Items and Purchase Orders...

    Help...Please...
    We have a problem, we run stock close to minimum at all times, (we supply short dated food stuff), and often our customers ask when the next delivery is due in.
    Now, we can drag and relate etc but often our staff just don't have time to search through the purchase orders to find the correct item and then when it's due in etc...
    I am trying to create a UDF that sits on the item master data and for each item runs a query that states the date the item is due in from the purchase order.
    So, in english/sql I need,
    Select item shown and find appropriate purchase orders, select top 1, (ie the next delivery date), and enter it into the UDF...
    I really am stuck in a way to code it, I've tried various ways but I think I'm going about it the wrong way or I'm missiong something, a date function / variable...
    Can anyone help?
    Cheers,
    Gary

    Hello Gary,
    Here is the sql:
    SELECT TOP 1 T1.ShipDate FROM OPOR T0  INNER JOIN POR1 T1 ON T0.DocEntry = T1.DocEntry WHERE T1.ItemCode =$[OITM.ItemCode] ORDER BY T1.ShipDate desc FOR BROWSE
    Just save it and link to the UDF.
    RGDS,
    Zsolt

  • When button press it should validate item and open another popup window

    apex 4.2.1
    I am having difficulties on it please help.
    I have a report and link and it open a page (popup window ) and it has items say, :p2_item_no and :p2_Final_Date (Date) and button submit and cancel.
    this page has process that is fetced the data for some hidden items. for example. :p2_Last_date (hidden).
    all above work ok but when hit the submit button then :p2_final_date item should be validated with :p2_last_date item
    so if :p2_final_date < :p2_last_date then error else accept the date value and same time go to the page 3 (another popup window).
    so from same submit button it must control both action. first validate and if success then open another page (popup window).
    thanks for help!
    RI.

    You can create an item level validation of type PL/SQL Expression on the popup page opened from the report.
    The item you would create the validation on would be P2_FINAL_DATE and the pl/sql expression you would use would be:
    :p2_final_date >= :p2_last_date;--Keith                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Getting "open recent" items and "open documents" from an application

    How do I ask Textedit (if running) for the list of documents currently open?
    How do I ask Textedit (if running ) for the list of "open recent" items?
    Thank you

    Thank you. This does the job for "opened documents" in TextEdit and other applications. I wish there were a similar method for "open recent" items. Each application (TextEdit, BBEdit etc) seems to handle the "open recent" items in its own way!
    Thank you again.

  • Link between delivery line item and sales order item schedule line.

    Hello friends,
    This is a continuation of my earlier query - for which I got half the solution, and this is the remaining problem.
    I want to know: from delivery document line item, how to link it to sales order line item's schedule line (when there are multiple schedule lines with identical quantities).
    Thanks for your help.
    - Chetan

    This is the code which i used for the same purpose and its working.
    Hope this will help you too....
    ****it_itab  is my final internal table.
    *Internal table for manupulating the Delivery balance when
    *its used in more than one schedule line
    TYPES: BEGIN OF ty_new,
           vbeln TYPE vbep-vbeln," so no
           posnr TYPE vbep-posnr," so line no
           etenr TYPE vbep-etenr," schedule line
           delno TYPE lips-vbeln,"delivery no
           delposnr TYPE lips-posnr,"del item no
           totval TYPE vbep-wmeng," total del wise value
           val   TYPE vbep-wmeng," del wise used value
           sdval TYPE vbep-wmeng,"schedule wise  del used value
           sdtotval TYPE vbep-wmeng," total Schedule value
         END OF ty_new.
    DATA:it_new TYPE ty_new OCCURS 0,
         wa_new TYPE ty_new.
    DATA: it_vbepvb TYPE TABLE OF vbepvb,
            wa_vbepvb LIKE LINE OF it_vbepvb,
            fvbfa TYPE TABLE OF vbfa,
            fvbup TYPE TABLE OF vbup,
            fvbap TYPE TABLE OF vbapvb.
      LOOP AT it_vbak INTO wa_vbak.
        LOOP AT it_vbap INTO wa_vbap
                WHERE vbeln = wa_vbak-vbeln.
      SELECT * FROM   vbfa INTO TABLE fvbfa WHERE vbelv = wa_vbap-vbeln
                                             AND  posnv = wa_vbap-posnr.
      SELECT * FROM   vbup INTO TABLE  fvbup WHERE vbeln = wa_vbap-vbeln
                                             AND  posnr = wa_vbap-posnr.
      SELECT * FROM   vbap INTO TABLE fvbap WHERE vbeln = wa_vbap-vbeln
                                             AND  posnr = wa_vbap-posnr.
      SELECT * FROM   vbep INTO TABLE it_vbepvb WHERE vbeln = wa_vbap-vbeln
                                             AND  posnr = wa_vbap-posnr.
      CALL FUNCTION 'RV_SCHEDULE_CHECK_DELIVERIES'
        EXPORTING
          fbeleg                        = wa_vbap-vbeln
          fposnr                        = wa_vbap-posnr
      FVERRECHNUNG                  = ' '
      FS073_ALT                     = ' '
      IF_NO_SORT                    = ' '
        TABLES
       fvbfa                         = fvbfa
       fvbup                         = fvbup
       fxvbep                        = it_vbepvb
      FVBLB                        =
        fvbap                        = fvbap
    EXCEPTIONS
      FEHLER_BEI_LESEN_FVBUP        = 1
      FEHLER_BEI_LESEN_FXVBEP       = 2
      OTHERS                        = 3
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      SORT it_vbepvb BY vbeln posnr edatu.
      LOOP AT it_vbepvb INTO wa_vbepvb
                    WHERE vbeln = wa_vbap-vbeln
                      AND posnr = wa_vbap-posnr.
        to write data of schedule line with no delivery
        MOVE wa_vbepvb-olfmng_flt TO wa_itab-openqty.
        IF  wa_vbepvb-bmeng EQ wa_itab-openqty.
          CLEAR wa_itab.
          PERFORM schedule_data.  "schedule line based data to be displayed
          MOVE: wa_vbap-lgort TO wa_itab-lgort.
          MOVE: wa_vbepvb-etenr TO wa_itab-etenr,
                wa_vbepvb-bmeng TO wa_itab-kwmeng,
                wa_vbepvb-olfmng_flt TO wa_itab-openqty.
          APPEND wa_itab TO it_itab .
          CLEAR wa_itab.
        ENDIF.
        LOOP AT it_vbfa INTO wa_vbfa WHERE vbelv = wa_vbepvb-vbeln
                                            AND  posnv = wa_vbepvb-posnr.
          READ TABLE it_likp INTO wa_likp WITH KEY vbeln = wa_vbfa-vbeln.
          CHECK wa_likp-bldat >= wa_vbepvb-edatu.
    check the Delivery doc date with the schedule line confirmed date
          CLEAR: delbal, deltot,wa_new.
          LOOP AT it_new INTO wa_new WHERE vbeln = wa_vbepvb-vbeln
                                         AND       posnr = wa_vbepvb-posnr
                                         AND       etenr = wa_vbepvb-etenr.
            deltot = deltot  +  wa_new-sdval.
          ENDLOOP.
          delbal = wa_new-sdtotval - deltot.
          CHECK sy-subrc <> 0 OR delbal GT 0.
          MOVE wa_vbepvb-olfmng_flt TO wa_itab-openqty.
          CHECK  wa_vbepvb-bmeng NE wa_itab-openqty.
    ****To check whether this delivery is already fully allocated against
    any other schedule.
    LOOP AT it_lips INTO wa_lips WHERE  vbeln = wa_vbfa-vbeln
                                           AND posnr = wa_vbfa-posnn.
            MOVE: wa_likp-bolnr TO wa_itab-vesname.
            MOVE: wa_likp-vbeln TO wa_itab-delno.
            MOVE: wa_likp-wadat TO wa_itab-wadat.
            MOVE: wa_likp-anzpk TO wa_itab-anzpk.
            MOVE: wa_likp-lddat TO wa_itab-lddat.
            MOVE: wa_likp-ernam TO wa_itab-ernam.
    ******end of code added by IVL1 on sep 27 2007 #3618
            PERFORM schedule_data.
            IF wa_lips-umvkz <> 0.
              tempquant = wa_lips-umvkn / wa_lips-umvkz.
            ELSE.
              tempquant = wa_lips-umvkn. "delivery qty
            ENDIF.
            tempquant = tempquant * wa_vbfa-rfmng.
    ***New logic added to get delivery qty schedule wise****
            MOVE: wa_vbepvb-etenr TO wa_itab-etenr,
                  wa_vbepvb-bmeng TO wa_itab-kwmeng,
                  wa_vbepvb-olfmng_flt TO wa_itab-openqty. "jo
    **if delivery qty is less than or equal to schedule line qty******
            IF tempquant LE  wa_vbepvb-bmeng.
              wa_itab-delqty =  tempquant.
              LOOP AT it_new INTO wa_new  WHERE  vbeln = wa_vbepvb-vbeln
                                         AND     posnr = wa_vbepvb-posnr
                                         AND     etenr = wa_vbepvb-etenr
                                         AND     delno  = wa_lips-vbeln
                                         AND     delposnr = wa_lips-posnr.
                MOVE-CORRESPONDING  wa_itab TO wa_new.
                wa_new-delposnr = wa_lips-posnr.
                wa_new-val = tempquant.
                wa_new-totval = tempquant.
                wa_new-sdval  = tempquant.
                wa_new-sdtotval = wa_vbepvb-bmeng.
                MODIFY TABLE it_new FROM wa_new .
                IF NOT sy-subrc IS INITIAL.
                  APPEND wa_new  TO it_new.
                ENDIF.
              ENDLOOP.
              IF sy-subrc <> 0.
                MOVE-CORRESPONDING  wa_itab TO wa_new.
                wa_new-delposnr = wa_lips-posnr.
                wa_new-val = tempquant.
                wa_new-totval = tempquant.
                wa_new-sdval  = tempquant.
                wa_new-sdtotval = wa_vbepvb-bmeng.
                APPEND wa_new TO it_new.
              ENDIF.
             wa_itab-delqty =  tempquant.
             CLEAR tempquant.
            ELSE.
        lips qty > so schedule lineqty
              CLEAR deltol.
              LOOP AT it_new INTO wa_new WHERE    vbeln = wa_vbepvb-vbeln
                                          AND      posnr = wa_vbepvb-posnr
                                         AND     etenr = wa_vbepvb-etenr
                                          AND     delno  = wa_lips-vbeln
                                          AND    delposnr = wa_lips-posnr.
                deltol = deltol  + wa_new-val.
              ENDLOOP.
              LOOP AT it_new INTO wa_new  WHERE    vbeln = wa_vbepvb-vbeln
                                          AND      posnr = wa_vbepvb-posnr
                                          AND     delno  = wa_lips-vbeln
                                          AND    delposnr = wa_lips-posnr.
                MOVE-CORRESPONDING  wa_itab TO wa_new.
                wa_new-val = wa_new-totval - deltol.
                wa_itab-delqty =  wa_new-val.
                wa_new-delposnr = wa_lips-posnr.
                wa_new-totval = tempquant.
                wa_new-sdval  = wa_new-val.
                wa_new-sdtotval = wa_vbepvb-bmeng.
                MODIFY TABLE it_new FROM wa_new .
                IF NOT sy-subrc IS INITIAL.
                  APPEND wa_new  TO it_new.
                ENDIF.
              ENDLOOP.
              IF  sy-subrc <> 0.
                MOVE-CORRESPONDING  wa_itab TO wa_new.
                wa_itab-delqty =  wa_vbepvb-bmeng.
                wa_new-delposnr = wa_lips-posnr.
                wa_new-val =  wa_vbepvb-bmeng.
                wa_new-totval = tempquant.
                wa_new-sdval  = wa_vbepvb-bmeng.
                wa_new-sdtotval = wa_vbepvb-bmeng.
                APPEND wa_new  TO it_new.
              ENDIF.
            ENDIF.
            IF NOT wa_lips-lgort IS INITIAL.
              MOVE: wa_lips-lgort TO wa_itab-lgort.
            ELSE.
              MOVE: wa_vbap-lgort TO wa_itab-lgort.
            ENDIF.
            APPEND wa_itab TO it_itab .
            CLEAR wa_itab.
          ENDLOOP. 
        ENDLOOP.
        CLEAR wa_vbepvb.
      ENDLOOP.
        ENDLOOP.
        CLEAR wa_vbak.
      ENDLOOP.

Maybe you are looking for

  • How to call function behind the button and update only specific record

    Greetings, 1 - i wnat to ask few things as i m new to apex, i am using apex 4.1, and created 3 select list and a button in seleting of parameter, 1 select list : select area 2 select list: select product 3- select list - size of the product i want to

  • Master password incorrect sometimes..?

    After not using my desktop for a week, I came home and woke up my computer and the "required password" that I requested to wake up my computer came up. I entered in THE CORRECT password, many many times, and it said incorrect. I shut down the mac, st

  • Autonumbering corrupted when converting RoboHelp HTML 5 to 8.

    everal problems: 1 RH 8 "created" multiple definitions in my .css file for a each style. 2 Autonumbered procedures (nested <ol> </ol> in original Help project was stable, but is not correct in RH8 3 User documentation for Font Family is incorrect/inc

  • Clarification for FAGLL03

    Hi Abapers, I'm facing a problem in FAGLL03, pls refer my thread which i posted in FI, FAGLL03 -not getting the quantity field update for RE doc type they suggested to do by blw method. so can any one help me out on blw issue .. How to use the Badi (

  • Proxy Rotator

    In my bash scripts I am able to cycle through proxies with something simple like: for line in $(cat $PROXY) do export http_proxy="http://$line" However, this type of loop will freeze the script if any of the proxies go off. Is there a proxy rotator p