Selection Criteria in Supply Chain Cockpit

Hello,
Is it possible to add some selection Criteria to add object in the work area ? For example I would like to add the ABC indicator as selection criteria to load in my work area only Product that have a class A indicator.
Thanks for your help.
Laurent.

Hello,
If you want to use the Alert Monitor within the Supply Chain Cockpit (SCC) in SAP APO, you must assign application-specific alert profiles to your SCC user profile. In the upper right area of the SCC, you can see the existing alerts for the applications.
Please look into the below link for more information:
http://help.sap.com/saphelp_scm70/helpdata/en/47/f925c8852f383ce10000000a42189b/content.htm
Regards

Similar Messages

  • SNP resource overload alerts not appearing in Supply Chain Cockpit

    I am using APO 5.1.
    We use APO SNP for capacity planning, and can see various capacity overload alerts in the alert monitor.
    But even though the Supply Chain Cockpit is linked to the correct alert profile, we do not see these alerts attached to the respective objects in the Supply Chain Cockpit.
    Any ideas on why this should be?...

    Hello,
    If you want to use the Alert Monitor within the Supply Chain Cockpit (SCC) in SAP APO, you must assign application-specific alert profiles to your SCC user profile. In the upper right area of the SCC, you can see the existing alerts for the applications.
    Please look into the below link for more information:
    http://help.sap.com/saphelp_scm70/helpdata/en/47/f925c8852f383ce10000000a42189b/content.htm
    Regards

  • Supply Chain Cockpit

    Hi all,
    can any one please explain me the purpose, working and application of the SCC in detail ???
    Thanks a lot in advance,
    PP

    Hi PP,
    The Supply Chain Cockpit (SCC) consists of a highly intuitive, graphical interface that acts as the top enterprise planning layer covering all planning areas such as manufacturing, demand, distribution, and transportation.
    All employees in the Plan -> Source -> Make -> Deliver cycle of supply chain management can use it to their advantage
    As the gateway to SAP APO, the SCC makes dealing with a vast supply chain easier and more manageable. SCC allows you to:
    Create individual work areas so several planners can work simultaneously on different parts of a supply chain.
    View the supply chain from all angles, down to the smallest detail, to minimize the complexity of the relationships among supply chain components.
    Measure supply chain performance with KPIs (key performance indicators) that are stored in SAP Business Intelligence (SAP BI).
    Respond immediately and accurately to new developments by tracking alert situations.
    The SCC can be configured to suit conditions within a wide variety of industries and business situations.
    For still more informations, please refer link
    http://www.e-optimization.com/resources/uploads/ACF308.pdf
    Regards
    R. Senthil Mareeswaran.

  • Save selection criteria in payment wizard

    Hello,
    Does anyone know what the option 'Save selection criteria only' at the end of the payment wizard actually means?  Does it mean it will save the criteria you choose e.g selecting a specific property and BP group or does it mean it will save the results returned from your selection criteria the previous time you ran it?
    Many thanks,
    Kate

    Hi Gordon,
    I thought the same however when I tested this it did not seem to work in this way.  I selected property 6 which returned one business partner which was correct and when I got to the last step of the payment wizard i chose 'Save selection criteria only'.  I then went into the BP master data record of a different supplier and ticked property 6.  When I went back into the payment wizard and went through the one I had just saved, the second business partner was not displayed.  If i then start a new payment run and choose property 6 in the selection criteria, both suppliers were shown.  It seems to only be saving the results that it returns from the selection criteria rather than the selection criteria itself.
    Kind regards,
    Kate

  • Change LO Cockpit Initialization Selection Criteria

    We would like to use the 2LIS_12_VCITM DataSource at our organization to report on delivery information.  I am encountering a problem because I would only like to Initialize data pertaining to specific shipping points. 
    The statistical setup does not contain shipping point or any other field I can use to exclude the data I do not want.  If I am forced to do the setup for all data and filter in the update rules my volume & runtime will be unnecessarily large.
    Is there any way to add additional fields to the selection screen ( OLI8BW ) ?
    Thank you!

    Unfortunately none of the delivered selection criteria for the Statistical Setup will eliminate the documents we don't want to include.
    The delivered options are:
    Archiving Session (N/A)
    Sales Org (Doesn't Differentiate as needed)
    Company Code (Doesn't Differentiate as needed)
    Sales Doc # (No specific range that matches requirements)
    Any other suggestions that would allow me to add another field to the selection options?

  • Ageing report selection criteria

    Hello Solution  Management,
    It is sometimes necessary to select only a special range of suppliers or customers.
    This could be achieved by selecting a range of groups or excluding a groupe or a range of group in the selection criteria.
    this criteria  would be similar to those in the stock posting list seletion criteria, BP tab for the range of group and on the tab by warehouse . The difference would be that instead of being warehouses it would be BP groups.
    KR/MFG/Bivacha
    Murielle

    Hello Marta,
    This is system default function.  It is hard coded already.  You could print this page on the virtual printer instead.
    Check this thread to have more info:
    Suppress Printing of Selection Criteria page
    Thanks,
    Gordon

  • No Print of the Customer Receivables Ageing Selection Criteria Page

    Hello.
    I would like to know how can I print the Customer Receivables Ageing / Supplier Liabilities Ageing Report without printing the selection criteria page, because when I try to print these reports I always get the selection criteria page. I've searched in the print options, but I didn't found anything.
    Can anyone help me?
    Thanks.
    Best Regards, Marta

    Hello Marta,
    This is system default function.  It is hard coded already.  You could print this page on the virtual printer instead.
    Check this thread to have more info:
    Suppress Printing of Selection Criteria page
    Thanks,
    Gordon

  • Jdeveloper set up for MSCA(Mobile supply chain application) custom page

    Hi Everyone,
    Can anyone provide me with the jdeveloper setup instructions to write class files for MSCA Application. I was trying to redo the helloworld tutorial from anil passi.com(http://oracle.anilpassi.com/hello-world-mobile-supply-chain-application-framework-6.html). But when i write import statements as below, jdeveloper does't recognize these import statements and throws error when i try to compile.
    import oracle.apps.inv.utilities.server.UtilFns;
    import oracle.apps.mwa.beans.FieldBean;
    import oracle.apps.mwa.container.Session;
    import oracle.apps.mwa.eventmodel.AbortHandlerException;
    import oracle.apps.mwa.eventmodel.DefaultOnlyHandlerException;
    import oracle.apps.mwa.eventmodel.InterruptedHandlerException;
    import oracle.apps.mwa.eventmodel.MWAEvent;
    import oracle.apps.mwa.eventmodel.MWAFieldListener;
    The steps I did in jdeveloper are:
    1) Created OA Workspace
    2) Create project under it with a package structure xxx.oracle.apps.inv.customfunction.server
    3) Right click on project and selected New Java Class file
    4) Wrote code in the java class file.
    So what exactly i should do so that i can compile my code in jdeveloper without errors. ( I know that we have to deploy these files to apps instance inorder to execute. I just want to compile it in jdeveloper).
    Thanks
    Sunny
    Edited by: user13369509 on Mar 16, 2011 8:49 AM

    my issue is resolved. i'm getting this problem when i add just java class file to the project. but when i also add the business componets and page component and generate controller class to the project , i can see that import is recognized by the java class file. So i guess i have to delete all the unwanted business components that i have created at the end.
    Thanks
    Sunny
    Edited by: user13369509 on Mar 16, 2011 12:44 PM

  • Automatic population of selection criteria in Infopakage

    Hi Experts,
    I have a Full Load Infopakage in a process chain that runs daily. I want to automatically populate posting date in the selection criteria of this Infopakage.
    For example:
    If the process chain runs on 20 July'08, then the posting date should be 19 July'08 (system date - 1).
    Currently we have to manually enter the posting date in the Infopakage selection criteria, but our requirement is to populate it automatically using some routine or formula. How can we do this?
    Points will be rewarded.

    Senoy, take a look at the following post
    [Routines in infopackage|Re: Can i interactively input data in a infopackage in a Process Chain?;

  • BW ignores selection criteria in a Infopackage after transport

    Hi all,
    After transporting Infopackages with selection criteria the target system ignores them. If I create further Infopackages on the target system everthing is fine. It seems as if the criteria were not transported but they are displayed. I replaced the criteria, saved the infopackage again but this didn't solve my issue.
    We are using BW 7.0 Level 14.
    Any ideas?
    Many thanks, Dennis

    Hi Srini,
    thanks for your quick repsonse. I am talking about 10 Infopackages. I transported some of them again but always the same issue. I created new infopackages on production and indeed it works but I use them in process chains and therefoe I might change the chains on production. This is something I don't want to do.
    Any other ideas?
    Cheers, Dennis

  • Can we change parameter descriptions in Selection Criteria. YES we can!

    Dear All,
    I have been struggling some time on some way to change the parameter descriptions in the Query - Selection Criteria screen.
    While doing numerous tests on trial-and-error, I accidentally hit upon a solution which appears to work!
    To change a parameter description, we simply have to reverse the order in which the WHERE clause is written.
    Please refer to the Query below:
    I used Customization Tools to create a UDT called @SCANNING
    and a UDF called U_ourref
              Title   : ourref
              Description : Our Reference
    If I use WHERE clause the conventional way, ie
    WHERE
    T1.[ImportLog] = @ourref
    I get the following Selection Criteria screen:
    Query - Selection Criteria Screen
    Import Log         .........................
    [OK]   [Cancel]
    If I write WHERE clause by interchanging the 2 sides of the equality, i.e
    WHERE
    @ourref = T1.[ImportLog]
    I get this screen:
    Query - Selection Criteria Screen
    Our Reference         .........................
    [OK]   [Cancel]
    Well! Is this not a way of changing the parameter description?
    And it works!
    My Problem
    The solution is nice. However, I wanted to use LIKE instead of EQUAL TO
    in order to allow Query to search for similar items.
    With the conventional clause, I can use '%[%1]%' in declaration and LIKE in the WHERE clause.
    With the reverse clause, I cannot figure out how to do it.
    Could anybody help?
    Thanks
    Leon Lai
    declare @ourref nvarchar (30)
    set @ourref =
    /*select T2.U_ourref FROM [dbo].[@SCANNING] T2 where T2.U_ourref*/ '[%1]'
    SELECT
    T0.[TaxDate] AS 'Doc Dt',
    T0.[DocNum] AS 'SAP Ref.',
    T0.[CardName]  AS 'Supplier Name',
    T0.[DocTotal]  AS 'Amount',
    T1.[ImportLog] AS 'Our Ref',
    T1.[BlockNum]  AS 'Reqn No.'
    FROM [dbo].[OPCH] T0
    INNER JOIN [dbo].[PCH1] T1 ON T0.[DocEntry] = T1.[DocEntry]
    INNER JOIN [dbo].[OJDT] T2 ON T0.[TransID] = T2.[TransID]
    WHERE
    @ourref = T1.[ImportLog]

    Dear István Korös  ,
    My main concern was modifying the Parameter Description in the Selection Criteria Screen.
    I certainly tried your suggestion, and it works, but unless I modified the WHERE Clause
    from :
    T1.[ImportLog].@ourref
    to:
    @ourref = T1.[ImportLog]
    the Selection Criteria screen shows:
    Query - Selection Criteria Screen
    Import Log         .........................
    [OK]   [Cancel]
    It is only after I have 'primed' the system by using:
    WHERE
    @ourref = T1.[ImportLog]
    that the Parameter Description changes to:
    Query - Selection Criteria Screen
    Our Reference         .........................
    [OK]   [Cancel]
    I can then use your line:
    WHERE T1.[ImportLog] like '%'@ourref'%'
    without any problem. The amended Parameter Description remains!
    I noticed something strange:
    Once I have 'primed' the system, it always shows the amended description on the Selection screen!
    Before priming, it always showed the system description.
    Don't know why?
    Anyway, I found a trick to 'prime' the system in all my queries to make sure the amended name appears
    on the Selection screen. I write:
    WHERE
    (@ourref    = T1.[ImportLog] OR
    T1.[ImportLog] like '%'@ourref'%')
    The first line is just for priming to ensure the Parameter Name will be changed.
    The 2nd line is the correct code to use.
    With this trick, we can change the Parameter Descriptions to whatever name we want.
    The only problem is that you lose the function List of available values.
    Thanks a lot,
    Leon Lai

  • Supply Chain Planner Work Bench: Dependent Demand Quantity in Horizontal Pl

    Hi,
    Does any one have idea on how to calculate 'Dependent Demand Quantity' in Supply Chain Planner's work bench.
    (in Horizontal Plan)
    This is dependent (component)demand quantity amount for a given item(Finished good or Assembly).
    Navigation:
    Application: Advanced Supply Chain Planner
    Supply Chain: Supply Chain work Bench (select this)
    (select org)
    Plan--> (select any plan)--->current recommendations-->(select org again)-->select item --> select horizontal plan in right side screen-->then u see Dependent Quantity.
    I need the formulate to calculate this.
    Any help is appreciated.
    Thanks,
    Srikanth Ramaraju

    Dependendent Demand for a component can represent the Discrete Job Demand and Planned Order demand (from the parent). If the component's final assembly has a discrete that is open and any planned orders against it, all of this demand is summed up in dependent demand at the component level. You can see the detail once you query the supply/demand from the workbench for the item prior to going to the horizontal plan.
    hope this helps!
    Nadi

  • Supply chain Planner - SNP

    Dear Experts,
    Have question regarding supply planner in SNP
    what is the purpose of supply chain planner in APO , can  i compare this SNP planner to MRP controller
    if i compared can i have view like MD05 collective access in APO ? 
    what is the best practice to define and organize snp planner ?
    Regards
    Raj 

    Hi Rajkumar,
    There is nothing like MD05 in APO.
    In APO you can use /SAPAPO/RRP3 which is comparable with MD04, but there is nothing like MD05.
    MRP controllers are CIF'd as Production Planner in APO.
    If you want to CIF the SNP Planner, you will need to add some logic: use the Exit EXIT_/SAPAPO/SAPLCIF_PROD_001 in APO.
    You can use the SNP planner in different reports / transactions:
    /SAPAPO/RRP1
    /SAPAPO/RRP4
    /SAPAPO/SDP94
    /SAPAPO/SNP94
    /SAPAPO/AMON1 - Alert Monitor (previous using the SNP planner in a selection profile in a planning book)
    /SAPAPO/SNP01 - SNP Planning Run (previous using the SNP planner in a selection profile in a planning book)
    etc.. etc..
    Kind Regards,
    Mariano

  • SUBMIT rkaep000 with "Further Selection Criteria"

    Hi all,
    Could anyone please tell me how to call the transaction KSB1 with it's "Further Selection Criteria" (i.e. Document Number). I have tried the following but it didn't work.
    SUBMIT rkaep000
      WITH p_tcode = 'KSB1'
      WITH kostl = '7062'
      WITH r_belnr BETWEEN '101727316' AND '101727316'
      WITH r_budat BETWEEN '20070101' AND '20070131'
      AND RETURN.
    Many thanks!
    Steve.

    try using submit rkaep000 with with selection-table t_Screen_tab.
    t_screen_tab is a table of type rsparams.
    rsparams is a structure with following field.
    SELNAME
    KIND
    SIGN
    OPTION
    LOW
    HIGH
    fill with an entry for each screen selection object.
    eg.
    t_screen_Tab-selname = 'R_BELNR'.
    t_Screen_tab-kind = 'S'. "S for select option, P for parameter
    t_Screen_tab-sign = 'I'. "I include E exclude
    t_screen_tab-option = 'BT'. "between, EQ or NE
    t_Screen_Tab-low = '101727316'.
    t_screen_tab-high = '101727316'.
    append t_screen_Tab.
    repeat for all selection entries required.
    Here is the abap help on topic
    Addition 3
    ... WITH SELECTION-TABLE rspar
    Effect
    If you specify this addition, parameters and selection criteria on the selection screen are supplied from an internal table rspar. You must specify an internal table with the row type RSPARAMS for rspar. The structured data type RSPARAMS is defined in the ABAP Dictionary and has the following components, all of which are data type CHAR:
    SELNAME (length 8),
    KIND (length 1),
    SIGN (length 1),
    OPTION (length 2),
    LOW (length 45),
    HIGH (length 45).
    To supply parameters and selection criteria for the selection screen with specific values, the lines in the internal table rspar must contain the following values:
    SELNAME must contain the name of a parameter or selection criterion for the selection screen in block capitals
    KIND must contain the type of selection screen component (P for parameters, S for selection criteria)
    SIGN, OPTION, LOW, and HIGH must contain the values specified for the selection table columns that have the same names as the selection criteria; in the case of parameters, the value must be specified in LOW and all other components are ignored.
    If the name of a selection criterion is repeated in rspar, this defines a selection table containing several lines and passes it on to the selection criterion. If parameter names occur several times, the last value is passed on to the parameter.
    The contents of the parameters or selection tables for the current program can be entered in the table by the function module RS_REFRESH_FROM_SELECTOPTIONS.
    Note
    In contrast to selection tables, the data types of the components LOW and HIGH in table rspar are always of type CHAR and are converted to the type of the parameter or selection criterion during transfer, if necessary.

  • Selection Criteria addition-Not working

    Hi!
    I have this report wherein I need to add two fields VBAP-Kunnr and knvv-konda in the selection screen so that I can do my drill down or search criteria based upon these two selections also apart from the existing ones, but unfortunately I am unable to get throiugh this and somehow putting this two selections in the selection criteria its not taking any effect or its just actinga  dummy selection and I am unale to drill down my report based upon those. Can anyone have a look and let me know what could be the problem please. Help would be highly appreciated.
    Thanks
    *& Include ZSD_PFGENERATETOP Report ZSD_PFGENERATE
    REPORT zsd_pfgenerate LINE-SIZE 170 LINE-COUNT 65.
    TABLES: lips, likp, vbap, vbak, vbrp, vbpa, vbrk.
    CONSTANTS: cns_vgtyp TYPE vbrp-vgtyp VALUE 'J',
    cns_intyp TYPE vbrk-vbtyp VALUE 'M',
    cns_vkorg TYPE vbak-vkorg VALUE 'CA01',
    cns_vkorg_US type vbak-vkorg value 'US01', "DEVK903521
    cns_parsh TYPE vbpa-parvw VALUE 'WE',
    cns_parsp TYPE vbpa-parvw VALUE 'AG',
    cns_parre type vbpa-parvw value 'RE', "bill-to
    cns_auzwp TYPE vbak-auart VALUE 'ZWP',
    cns_auzct TYPE vbak-auart VALUE 'ZCT',
    cns_auzif TYPE vbak-auart VALUE 'ZIF',
    cns_auztm TYPE vbak-auart VALUE 'ZTM',
    cns_fkff TYPE vbrk-fkart VALUE 'ZFF5',
    cns_fkos TYPE vbrk-fkart VALUE 'ZOF5',
    cns_upd(1) TYPE c VALUE 'S',
    cns_mode(1) TYPE c VALUE 'N'.
    Internal Tables and Work Areas
    DATA: BEGIN OF it_vbpos OCCURS 0,
    werks TYPE vbap-werks,
    audat TYPE vbak-audat,
    auart TYPE vbak-auart,
    kunag TYPE vbak-kunnr,
    name1_ag TYPE kna1-name1,
    kunsh TYPE likp-kunnr,
    name1_sh TYPE kna1-name1,
    vbeln TYPE vbak-vbeln,
    posnr TYPE vbap-posnr,
    vbdel TYPE likp-vbeln,
    psdel TYPE lips-posnr,
    kunre type kunre, "Bill-to Party
    name1_re type kna1-name1, "Bill-to Party Name
    END OF it_vbpos,
    BEGIN OF it_vbpos_temp OCCURS 0,
    vgbel TYPE lips-vgbel,
    vgpos TYPE lips-vgpos,
    vbeln TYPE vbak-vbeln,
    posnr TYPE vbap-posnr,
    END OF it_vbpos_temp,
    BEGIN OF it_report OCCURS 0,
    werks TYPE vbap-werks,
    vbeln TYPE vbak-vbeln,
    vbdel TYPE likp-vbeln,
    audat TYPE vbak-audat,
    auart TYPE vbak-auart,
    name1_ag TYPE kna1-name1,
    name1_sh TYPE kna1-name1,
    name1_re type kna1-name1, "Bill-to Party Name
    mark(1) TYPE c,
    END OF it_report,
    BEGIN OF it_vbeln OCCURS 0,
    vbeln TYPE vbak-vbeln,
    END OF it_vbeln,
    wa_vbeln LIKE LINE OF it_vbeln,
    wa_vbpos LIKE LINE OF it_vbpos,
    wa_report LIKE LINE OF it_report,
    wa_sel LIKE LINE OF it_report.
    DATA: it_vbrp type table of vbrp,
    it_vbrk type table of vbrk.
    BDC Variables
    DATA: BEGIN OF bdc_tab OCCURS 0.
    INCLUDE STRUCTURE bdcdata.
    DATA: END OF bdc_tab.
    DATA: wa_bdc LIKE LINE OF bdc_tab,
    it_bdcmess TYPE TABLE OF bdcmsgcoll.
    *& Selection-Screen definition
    SELECTION-SCREEN BEGIN OF BLOCK block2 WITH FRAME TITLE text-002.
    PARAMETERS: p_rdff TYPE c RADIOBUTTON GROUP rad1 DEFAULT 'X',
    p_rdos TYPE c RADIOBUTTON GROUP rad1.
    SELECTION-SCREEN END OF BLOCK block2.
    SELECTION-SCREEN BEGIN OF BLOCK block0 WITH FRAME TITLE text-000.
    SELECT-OPTIONS: s_werks FOR vbap-werks OBLIGATORY NO INTERVALS,
    s_auart FOR vbak-auart,
    s_kunag FOR vbak-kunnr, "Sold-to Party
    s_kunnr FOR likp-kunnr, "Ship-to Party
    s_kunre for vbak-kunnr, "Bill to Party
    s_vdatu FOR vbak-vdatu OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK block0.
    SELECTION-SCREEN BEGIN OF BLOCK block1 WITH FRAME TITLE text-001.
    PARAMETERS: p_vgbel TYPE vbak-vgbel.
    SELECTION-SCREEN END OF BLOCK block1.
    selection-screen begin of block block3 with frame title text-003.
    parameters: p_billed RADIOBUTTON GROUP r1,
    p_delvd RADIOBUTTON GROUP r1 default 'X',
    p_all RADIOBUTTON GROUP r1.
    selection-screen end of block block3.
    *& Include ZSD_PFGENERATEE01
    START-OF-SELECTION.
    PERFORM read_report.
    END-OF-SELECTION.
    SET PF-STATUS 'STAT1000'.
    IF it_vbpos[] IS INITIAL.
    MESSAGE s999(z001) WITH 'No Data Selected for this criteria'.
    ELSE.
    PERFORM show_report.
    ENDIF.
    *& List Events
    AT USER-COMMAND.
    CASE sy-ucomm.
    WHEN 'SELE'.
    LOOP AT it_report INTO wa_report.
    wa_report-mark = 'X'.
    MODIFY it_report FROM wa_report.
    ENDLOOP.
    PERFORM show_report.
    WHEN 'DSEL'.
    LOOP AT it_report INTO wa_report.
    wa_report-mark = ''.
    MODIFY it_report FROM wa_report.
    ENDLOOP.
    PERFORM show_report.
    ENDCASE.
    AT LINE-SELECTION.
    DO.
    READ LINE sy-index FIELD VALUE wa_report-mark wa_report-vbeln
    wa_report-vbdel.
    IF sy-subrc NE 0.
    EXIT.
    ELSE.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
    input = wa_report-vbeln
    IMPORTING
    output = wa_report-vbeln.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
    input = wa_report-vbdel
    IMPORTING
    output = wa_report-vbdel.
    READ TABLE it_report INTO wa_sel
    WITH KEY vbeln = wa_report-vbeln.
    IF sy-subrc EQ 0.
    wa_sel-mark = wa_report-mark.
    MODIFY it_report FROM wa_sel INDEX sy-tabix.
    ENDIF.
    ENDIF.
    ENDDO.
    REFRESH: it_vbeln.
    LOOP AT it_report INTO wa_report WHERE mark EQ 'X'.
    CASE 'X'.
    WHEN p_rdff.
    wa_vbeln = wa_report-vbdel.
    WHEN p_rdos.
    wa_vbeln = wa_report-vbeln.
    ENDCASE.
    APPEND wa_vbeln TO it_vbeln.
    ENDLOOP.
    SORT it_vbeln BY vbeln.
    DELETE ADJACENT DUPLICATES FROM it_vbeln.
    IF NOT it_vbeln[] IS INITIAL.
    PERFORM process_vf01.
    ENDIF.
    *& Include ZSD_PFGENERATEF01
    *& Form read_report
    Routine to read applicable orders from database
    FORM read_report.
    DATA: lwa_lips TYPE lips,
    lc_vbeln TYPE vbrk-vbeln.
    Retrieve sales orders based on selection criteria where billing doc has not been
    created for the delivery yet
    REFRESH: it_vbeln, it_vbpos, it_report.
    Select into table based on Onsite/Fixed Facility
    CASE 'X'.
    WHEN p_rdff.
    changed for performance reasons (i.e. time-out)
    k~vgbel is not in it_vbpos but was in select statment ?
    SELECT vbap~werks vbak~audat vbak~auart vbak~kunnr AS kunag
    vbak~vbeln vbap~posnr
    INTO CORRESPONDING FIELDS OF TABLE it_vbpos
    FROM vbak INNER JOIN vbap
    ON vbak~mandt = vbap~mandt
    AND vbak~vbeln = vbap~vbeln
    WHERE vbap~werks IN s_werks
    AND vbak~vdatu IN s_vdatu
    AND vbak~vkorg in (cns_vkorg,cns_vkorg_US)
    AND vbap~oid_ship IN s_kunnr
    AND vbak~kunnr IN s_kunag
    AND vbak~auart IN s_auart
    AND ( vbak~auart = 'ZWP' or vbak~auart = 'ZIF' or
    vbak~auart = 'ZCT' or vbak~auart = 'ZTM' or
    vbak~auart = 'ZOIL' ).
    IF SY-SUBRC = 0.
    SELECT vgbel vgpos vbeln posnr FROM lips
    INTO CORRESPONDING FIELDS OF TABLE it_vbpos_temp
    FOR ALL ENTRIES IN it_vbpos
    WHERE vgbel = it_vbpos-vbeln
    AND vgpos = it_vbpos-posnr
    %_hints oracle 'index ("LIPS" "LIPS~Z01")'.
    SORT it_vbpos_temp by vgbel vgpos.
    LOOP AT it_vbpos.
    READ TABLE it_vbpos_temp
    WITH KEY vgbel = it_vbpos-vbeln vgpos = it_vbpos-posnr
    BINARY SEARCH.
    IF SY-SUBRC = 0.
    it_vbpos-vbdel = it_vbpos_temp-vbeln.
    it_vbpos-psdel = it_vbpos_temp-posnr.
    modify it_vbpos.
    ENDIF.
    ENDLOOP.
    ENDIF.
    WHEN p_rdos.
    SELECT k~vbeln p~posnr k~kunnr AS kunag k~audat k~auart p~werks k~vgbel
    INTO CORRESPONDING FIELDS OF TABLE it_vbpos
    FROM vbak AS k INNER JOIN vbap AS p ON k~vbeln = p~vbeln
    WHERE p~werks IN s_werks AND k~vdatu IN s_vdatu AND
    k~vkorg in (cns_vkorg,cns_vkorg_US) AND "DEVK903521
    k~vgbel EQ p_vgbel AND
    k~kunnr IN s_kunag AND k~auart IN s_auart AND
    p~oid_ship IN s_kunnr.
    ENDCASE.
    Determine if delivery has been billed out, if not can create PF Invoice - CHANGED
    LOOP AT it_vbpos INTO wa_vbpos.
    Check Ship-to in
    SELECT SINGLE kunnr INTO wa_vbpos-kunsh FROM vbpa
    WHERE parvw EQ cns_parsh AND vbeln EQ wa_vbpos-vbeln.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    Check for Bill-to
    select single kunnr into wa_vbpos-kunre from vbpa
    where parvw eq cns_parre and vbeln eq wa_vbpos-vbeln
    and kunnr in s_kunre.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    Get Partner Texts
    SELECT SINGLE name1 INTO wa_vbpos-name1_ag FROM kna1
    WHERE kunnr EQ wa_vbpos-kunag.
    SELECT SINGLE name1 INTO wa_vbpos-name1_sh FROM kna1
    WHERE kunnr EQ wa_vbpos-kunsh.
    SELECT SINGLE name1 INTO wa_vbpos-name1_re FROM kna1
    WHERE kunnr EQ wa_vbpos-kunre.
    CASE 'X'.
    WHEN p_rdff.
    IF p_delvd = 'X'.
    optimized for performance reasons i.e. time-out
    Check if delivery has been billed out
    SELECT SINGLE k~vbeln INTO lc_vbeln
    FROM vbrp AS p INNER JOIN vbrk AS k ON p~vbeln = k~vbeln
    WHERE p~vgtyp EQ cns_vgtyp AND p~vgbel EQ wa_vbpos-vbdel AND
    p~vgpos EQ wa_vbpos-psdel AND k~vbtyp EQ cns_intyp AND
    k~fksto NE 'X'.
    refresh: it_vbrp, it_vbrk.
    select vbeln from vbrp
    into corresponding fields of table it_vbrp
    where vgtyp = cns_vgtyp and vgbel = wa_vbpos-vbdel
    and vgpos = wa_vbpos-psdel
    %_hints oracle 'index ("VBRP" "VBRP~Z01")'.
    if sy-subrc = 0.
    sort it_vbrp by vbeln.
    delete adjacent duplicates from it_vbrp comparing vbeln.
    select vbeln from vbrk
    into corresponding fields of table it_vbrk
    for all entries in it_vbrp
    where vbeln = it_vbrp-vbeln
    and vbtyp = cns_intyp and fksto 'X'.
    IF sy-subrc EQ 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    endif.
    ELSEIF p_billed = 'X'.
    Check if delivery hasn't been billed out
    SELECT SINGLE k~vbeln INTO lc_vbeln
    FROM vbrp AS p INNER JOIN vbrk AS k ON p~vbeln = k~vbeln
    WHERE p~vgtyp EQ cns_vgtyp AND p~vgbel EQ wa_vbpos-vbdel AND
    p~vgpos EQ wa_vbpos-psdel AND k~vbtyp EQ cns_intyp AND
    k~fksto NE 'X'.
    refresh: it_vbrp, it_vbrk.
    select vbeln from vbrp
    into corresponding fields of table it_vbrp
    where vgtyp = cns_vgtyp and vgbel = wa_vbpos-vbdel
    and vgpos = wa_vbpos-psdel
    %_hints oracle 'index ("VBRP" "VBRP~Z01")'.
    if sy-subrc = 0.
    sort it_vbrp by vbeln.
    delete adjacent duplicates from it_vbrp comparing vbeln.
    select vbeln from vbrk
    into corresponding fields of table it_vbrk
    for all entries in it_vbrp
    where vbeln = it_vbrp-vbeln
    and vbtyp = cns_intyp and fksto 'X'.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    endif.
    ENDIF.
    WHEN p_rdos.
    IF p_delvd = 'X'.
    Check if order has been billed out
    SELECT SINGLE * FROM vbrp
    WHERE vbeln EQ wa_vbpos-vbeln AND
    vgpos EQ wa_vbpos-posnr.
    IF sy-subrc EQ 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    ELSEIF p_billed = 'X'.
    Check if delivery hasn't been billed out
    SELECT SINGLE k~vbeln INTO lc_vbeln
    FROM vbrp AS p INNER JOIN vbrk AS k ON pvbeln = kvbeln
    WHERE pvgtyp EQ cns_vgtyp AND pvgbel EQ wa_vbpos-vbdel AND
    pvgpos EQ wa_vbpos-psdel AND kvbtyp EQ cns_intyp AND
    k~fksto NE 'X'.
    refresh: it_vbrp, it_vbrk.
    select vbeln from vbrp
    into corresponding fields of table it_vbrp
    where vgtyp = cns_vgtyp and vgbel = wa_vbpos-vbdel
    and vgpos = wa_vbpos-psdel
    %_hints oracle 'index ("VBRP" "VBRP~Z01")'.
    if sy-subrc = 0.
    sort it_vbrp by vbeln.
    delete adjacent duplicates from it_vbrp comparing vbeln.
    select vbeln from vbrk
    into corresponding fields of table it_vbrk
    for all entries in it_vbrp
    where vbeln = it_vbrp-vbeln
    and vbtyp = cns_intyp and fksto 'X'.
    IF sy-subrc NE 0.
    DELETE TABLE it_vbpos FROM wa_vbpos.
    CONTINUE.
    ENDIF.
    endif.
    ENDIF.
    ENDCASE.
    MOVE-CORRESPONDING wa_vbpos TO wa_report.
    APPEND wa_report TO it_report.
    MODIFY it_vbpos FROM wa_vbpos.
    ENDLOOP.
    if 'onsite field summary', then process by release sales orders
    IF p_rdos = 'X'.
    sort it_report by vbeln.
    delete adjacent duplicates from it_report comparing vbeln.
    else.
    SORT it_report BY werks name1_ag name1_sh vbeln.
    DELETE ADJACENT DUPLICATES FROM it_report.
    endif.
    SORT it_report BY name1_sh werks name1_ag vbeln.
    ENDFORM. " read_report
    *& Form process_vf01
    Call transaction VF01 and fill screen table with order values
    FORM process_vf01.
    DATA: ln_index(2) TYPE n,
    lc_field(20) TYPE c,
    lc_fkart TYPE vbrk-fkart,
    li_lines TYPE i,
    lc_msgtxt(99) TYPE c,
    lwa_bdcoptions TYPE ctu_params,
    lwa_mess LIKE LINE OF it_bdcmess.
    REFRESH: it_bdcmess.
    lwa_bdcoptions-dismode = cns_mode.
    lwa_bdcoptions-updmode = cns_upd.
    CASE 'X'.
    WHEN p_rdff.
    lc_fkart = cns_fkff.
    WHEN p_rdos.
    lc_fkart = cns_fkos.
    ENDCASE.
    REFRESH: bdc_tab.
    PERFORM update_bdc USING: 'X' 'SAPMV60A' '0102',
    ' ' 'BDC_CURSOR' 'RV60A-FKART',
    ' ' 'RV60A-FKART' lc_fkart,
    ' ' 'BDC_OKCODE' '/00'.
    LOOP AT it_vbeln INTO wa_vbeln.
    ln_index = sy-tabix.
    Up to the second delivery of the BDC add the Delivery to the screen, after that click the More Documents for every entry. logic changed for DEVK902353
    CASE ln_index.
    WHEN 1.
    CONCATENATE 'KOMFK-VBELN' '(' ln_index ')' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln.
    WHEN 2 OR 3.
    IF p_rdos 'X'.
    CONCATENATE 'KOMFK-VBELN' '(' ln_index ')' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln,
    'X' 'SAPMV60A' '0102',
    ' ' 'BDC_OKCODE' 'FKAN'..
    ELSE.
    CONCATENATE 'KOMFK-VBELN' '(' ln_index ')' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln.
    ENDIF.
    WHEN OTHERS.
    If p_rdos 'X'.
    CONCATENATE 'KOMFK-VBELN' '(2)' INTO lc_field.
    PERFORM update_bdc USING: ' ' lc_field wa_vbeln,
    'X' 'SAPMV60A' '0102',
    ' ' 'BDC_OKCODE' 'FKAN'.
    endif.
    ENDCASE.
    ENDLOOP.
    VF01 will go to a different screen if only one line selected
    DESCRIBE TABLE it_vbeln LINES li_lines.
    IF li_lines EQ 1.
    PERFORM update_bdc USING: 'X' 'SAPMV60A' '0104',
    ' ' 'BDC_OKCODE' '=SICH'.
    ELSE.
    PERFORM update_bdc USING: 'X' 'SAPMV60A' '0102',
    ' ' 'BDC_OKCODE' '=SICH'.
    ENDIF.
    CALL TRANSACTION 'VF01' USING bdc_tab OPTIONS FROM lwa_bdcoptions
    MESSAGES INTO it_bdcmess.
    WRITE: / 'BDC Messages:'.
    SKIP.
    LOOP AT it_bdcmess INTO lwa_mess.
    CALL FUNCTION 'RH_MESSAGE_GET'
    EXPORTING
    arbgb = 'VF'
    msgnr = lwa_mess-msgnr
    msgv1 = lwa_mess-msgv1
    msgv2 = lwa_mess-msgv2
    msgv3 = lwa_mess-msgv3
    msgv4 = lwa_mess-msgv4
    IMPORTING
    msgtext = lc_msgtxt
    EXCEPTIONS
    message_not_found = 1
    OTHERS = 2.
    WRITE: /5 lc_msgtxt.
    ENDLOOP.
    ENDFORM. " process_vf01
    form update_bdc *
    subroutine to add the data to the bdc table for trans. vf01 *
    FORM update_bdc USING dynpro field content.
    CLEAR bdc_tab.
    IF dynpro EQ 'X'.
    bdc_tab-program = field.
    bdc_tab-dynpro = content.
    bdc_tab-dynbegin = 'X'.
    ELSE.
    bdc_tab-fnam = field.
    bdc_tab-fval = content.
    ENDIF.
    APPEND bdc_tab.
    ENDFORM. "UPDATE_BDC
    *& Form show_report
    Report to Display Available Orders on Screen
    FORM show_report .
    DATA: l_idx TYPE i.
    WRITE: / 'Available Orders/Deliveries for Plant:'.
    LOOP AT s_werks.
    WRITE: s_werks-low.
    ENDLOOP.
    SKIP.
    FORMAT INTENSIFIED ON COLOR COL_HEADING.
    WRITE: /5 text-h01, text-h02.
    CASE 'X'.
    WHEN p_rdff.
    WRITE: text-h06.
    ENDCASE.
    WRITE: text-h03, text-h04, text-h05, text-h07,
    / sy-uline.
    FORMAT INTENSIFIED OFF COLOR OFF.
    l_idx = 0.
    LOOP AT it_report INTO wa_report.
    IF l_idx EQ 0.
    FORMAT COLOR COL_NORMAL INTENSIFIED ON.
    l_idx = 1.
    ELSE.
    FORMAT COLOR COL_NORMAL INTENSIFIED OFF.
    l_idx = 0.
    ENDIF.
    WRITE: / wa_report-mark AS CHECKBOX,
    wa_report-auart UNDER text-h01,
    wa_report-vbeln UNDER text-h02.
    CASE 'X'.
    WHEN p_rdff.
    WRITE: wa_report-vbdel UNDER text-h06.
    ENDCASE.
    WRITE: wa_report-audat UNDER text-h03,
    wa_report-name1_ag UNDER text-h04,
    wa_report-name1_sh UNDER text-h05,
    wa_report-name1_re under text-h07.
    HIDE: wa_report-mark, wa_report-vbeln, wa_report-vbdel.
    ENDLOOP.
    ENDFORM. " show_report
    Thanks for your kind help.
    Aarav.

    Hi, Anne-Marie;
    You may be running into a common issue that is docuemented here:
    [SelectionFormula|https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_erq/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes%7B6163636573733d36393736354636443646363436353344333933393338323636393736354637333631373036453646373436353733354636453735364436323635373233443330333033303331333233303334333833393335%7D.do]
    Regards,
    Jonathan
    Edited by: Jonathan Parminter on Mar 16, 2009 8:03 AM

Maybe you are looking for

  • Report problem with PL/sql

    function BeforeReport return boolean is begin declare l_sort po_lookup_codes.displayed_field % type; begin if :P_orderby is not null then select displayed_field into l_sort from po_lookup_codes where lookup_code = :P_orderby and lookup_type = 'SRS OR

  • I would like to see history on my form from Day 1, currently I can only see partial history! Help!

    I would like to see history on my form from Day 1, currently I can only see partial history! Help!

  • Problem in insertion

    i have used addBatch method for the insertion of multiple values at a one time.. but its not working... conn.setAutoCommit(false); PreparedStatement pstmt = conn.prepareStatement( ("INSERT INTO gl_mast VALUES (?, ?, ?, ?, ?, ?)")); for (int n = 0; n

  • OCI Catalog for Vendor problem : Logical system for catalog not maintained

    We have set up an OCI catalog with on of our vendors. This works fine untill we transfer shopping basket data from Vendor sysem into our SRM-system (SRM5.0). Then data is not being transfered and Vendor Webshop screen remains 'open'. in SLG1 i have f

  • ITunes won't play quicktime videos on Mac anymore.

    I'm using 10.7.3 iTunes 10.6 MacBook Pro 2.6Ghz 4GB ram iTunes won't play my video anymore and it's been a while I'm not sure when it occured if it's after an update to snow leopard or iTunes updates... When I double click a video I get "This movie r