Set Filter Criteria Fields for ALV

Hi everyone!
Is there a way in ALV that you can set the filtering criteria fields for your ALV report, but not the field values itself?
To be more clear (I hope), When you run the ALV report, it initially shows you the entire report, but when you click on the FILTER button, there are already pre-selected fields for the filter criteria.
Thanks a lot.. points for any useful answer.

Hi,
Yes you can do with Layout button in the application tool bar.
First filter out the columns and save it with name.
Everytime you execute the program,click the layout button and select the layout variant .
regards,
Maha

Similar Messages

  • Set filter criteria on page 1 for page 2 OData model - "best practice"?

    Hello, I have a problem with an app - where I want to filter data on a second page, based on settings from the first page. I use an OData model.
    The collections on both pages are not related in terms of "navigation" properties, that is my problem and I can not change the data source...
    So I am looking for ideas/best practices to solve this because sometimes my filtering doesn't work... the following problem occurred: Request aborted
    I have a page with a sap.m List with items="{/tabWorkPlace}" and and a local JSON model where I store relevant data during the app lifecycle.
    handleListSelect - first page
    var context = evt.getParameter("listItem").getBindingContext();
    var dataModel = sap.ui.getCore().getModel("dataModel");
    var workplace = context.getProperty("WORKPLACE_ID");
    dataModel.setProperty("/WORKPLACE_ID", workplace);
    this.nav.to("SubMaster", context);
    The general App.controller.js handles the nav.to function:
    var app = this.getView().app;
    var page = app.getPage(pageId);
    if(pageId == "secondPage") {
         page.getController().filterData();
    And the controller of the second page:
    filterData: function() {
    var oModel = sap.ui.getCore().getModel("odata");
    var dataModel = sap.ui.getCore().getModel("dataModel");
    var workplace = dataModel.getProperty("/WORKPLACE_ID");
    var items = this.getView().byId("list");
    var oFilter=new sap.ui.model.Filter("WORKPLACE_ID",sap.ui.model.FilterOperator.EQ,workplace);
    items.getBinding("items").filter(oFilter);
    I don't write this code into the onInit() or beforeRendering() function, because they are called only once and I am navigating back and forth between the two pages, because the pages are created only once and "just" the data is changed.
    The desired page looks like this - with an other collection bound to it:
    <List
      id="list"
      select="handleListSelect"
      items="{/tabWorkstep_Status}"
    >
    But when I call it - then the request gets aborted:
    The following problem occurred: Request aborted
    But despite the fact the Request is aborted, the list on the second page is filtered!
    The filter criteria for the model works when I type it into the browser with URL. Maybe this fails because the data binding for the list didn't took place at this phase?
    I have this pattern (filter criteria on one page and result on the second page) more times - (and I think a better data model would be better with navigation properties would be better, but I cannot change it)
    But at another constellation the filtering doesn't work - same error... the following problem occurred: Request aborted
    I also don't want to change the pattern (page 1 to page 2) into popup lists or this fancy new filtering possibilities because it is not suitable for my use case.
    Is there maybe a more elegant solution - because sometimes filtering works, sometimes don't..., do I have an error in my solution (general approach)?
    Many thanks for any input!
    BR,
    Denise

    Hello, yeah you are right, but it works without the odata> stuff because of this in App.controller.js:
    var uri = "http://localhost:32006/JsonOdataService.svc";
    var oModelMS = new sap.ui.model.odata.ODataModel(uri);
    sap.ui.getCore().setModel(oModelMS, "odata");
    oView.setModel(oModelMS);
    So my question is - how to navigate from one page to another - and on the other page first bind a collection to a select and then when selecting bind certain elements (a textfield) to the selected filtered entity.
    The stuff with context and binding won't work, because the two Collections don't have a navigation/association property between them...
    So for example:
    page1
    select a list item with property color: red and year 1985. Press one of the buttons and pass this criteria to another page.
    page 2:
    show a dropdown box with all car names which fullfill this criteria, and when one car is selected, then display the data for THIS car in several text fields.
    This is not a master->detail navigation example, because on page 1 i select certain criterias, and then with buttons I navigate to several pages with those criterias.
    But since the OData model has no relationships it is really hard to do it manually... With a dummy mock.json like in DJ Adams Fiori like SAPUI5 apps it is no problem... But with OData and no things related to each other it is hard...

  • Set new Required Field for MD14 and MD15 for conver from Planned order to P

    Dear all,
    I would like to set new required field (Purchasing Organization)  in T-CODE MD14 and MD15 for convert from Planned Order to PR. What's should I do?
    Please help, I 'm new for MRP.
    Best Regards,
    Kate

    Hi Kate,
    You are not on the right track; MD14 and 15 will choose the PLANNED ORDER population for the conversion. In planned orders there's NO PURCHASING ORGANIZATION DATA (normally)!
    So even if you managed to put the field on the screen, it will not do anything that makes sense.

  • Setting the PF Status for ALV

    Hi all,
    How it would be possible to create a PF Status for ALV display. I want to add one button my ALV report.
    Thanks.
    Harshad.

    Hi ,
    You can create PF-status using the Statement :   set pf-status 'STATUS_NAME'  in a FORM as shown below:
    form frm_status using rt_extab type slis_t_extab.
      set pf-status 'STANDARD'.
    endform.
    Double click on the STATUS_NAME and it Navigates to the Screen Painter. There you can specify the Menu , Buttons as required.
    Instead of cretaing a new status you can also copy the existing Standard status as told above and use the required buttons / menu items.
    Now to handle the operations of these buttons :Include in a form as below
    form frm_usercommand using r_ucomm like sy-ucomm
                      rs_selfield type slis_selfield.
      case r_ucomm.
        when 'SUB'.
          <opertion as required>
        when 'SUB1'.
           <opertion as required>
      endcase.
    Endform.
    Pass these two form names to the FM REUSE_ALV_GRID_DISPLAY ( Parameters of FM : i_callback_pf_status_set   &  i_callback_user_command  ) and the result will be dispalyed with the new Status to the parameters  .
    call function 'REUSE_ALV_GRID_DISPLAY'
       exporting
        I_INTERFACE_CHECK                 = ' '
        I_BYPASSING_BUFFER                = ' '
        I_BUFFER_ACTIVE                   = ' '
         i_callback_program                = v_repid
         i_callback_pf_status_set          = 'FRM_STATUS'
         i_callback_user_command           = 'FRM_USERCOMMAND'
        I_CALLBACK_TOP_OF_PAGE            = ' '
        I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
        I_CALLBACK_HTML_END_OF_LIST       = ' '
        I_STRUCTURE_NAME                  =
        I_BACKGROUND_ID                   = ' '
        I_GRID_TITLE                      =
        I_GRID_SETTINGS                   =
        IS_LAYOUT                         =
         it_fieldcat                       = it_fieldcat
        IT_EXCLUDING                      =
        IT_SPECIAL_GROUPS                 =
        IT_SORT                           =
        IT_FILTER                         =
        IS_SEL_HIDE                       =
        I_DEFAULT                         = 'X'
        I_SAVE                            = ' '
        IS_VARIANT                        =
          it_events                         = it_event
        IT_EVENT_EXIT                     =
        IS_PRINT                          =
        IS_REPREP_ID                      =
        I_SCREEN_START_COLUMN             = 0
        I_SCREEN_START_LINE               = 0
        I_SCREEN_END_COLUMN               = 0
        I_SCREEN_END_LINE                 = 0
        I_HTML_HEIGHT_TOP                 = 0
        I_HTML_HEIGHT_END                 = 0
        IT_ALV_GRAPHICS                   =
        IT_HYPERLINK                      =
        IT_ADD_FIELDCAT                   =
        IT_EXCEPT_QINFO                   =
        IR_SALV_FULLSCREEN_ADAPTER        =
      IMPORTING
        E_EXIT_CAUSED_BY_CALLER           =
        ES_EXIT_CAUSED_BY_USER            =
        tables
          t_outtab                          = it_vbak
       exceptions
         program_error                     = 1
         others                            = 2
    Regards,
    Radhika.

  • How to set filter criteria for month and year using in timestamp input field?

    Hi,
    I am using jdev 11.1.2.3,
    I have one problem with Report generation,,,,,,I have one report table which is in the form of VO(query based) and i want to search this table as month and year basis
    but in this table(query) that field having timestamp based value.. how to search with month name and year only.. Here i am using totally query base VO's for generating
    reports........ Can any one guide me.
    Thank You.

    You can use a inputdate, which allows you to selecte a moth, year and a day. Once the selection is made you convert it to only allow moth and date like
            <af:inputDate label="Label 1" id="id1" autoSubmit="true" value="#{bindings.myMonthYear1.inputValue}">
              <f:convertDateTime pattern="MM/yyyy"/> 
            </af:inputDate>
            <af:outputText value="Selected #{bindings.myMonthYear1.inputValue}" id="ot1" partialTriggers="id1"/>
    then you have a string holding month and year only. This value you split into two variables you or pass it as a whole parameter to the query and split it there.
    Another way is to add two static lovs one for month and one for year and use them to get to the filter values.
    Timo

  • Set filter in R3AC1 for material master

    dear all,
    we are using SRM 5.0 (Extended Classic Scenario)
    we have done the base line configuration. now we are trying to replicate the data from backend (R/3)
    I have tried to set a filter in R3AC1 transaction. It is working fine for all except material master.
    It pops me an erro msg "Filter option '' is not possible for Object MATERIAL".
    There is a SAP note on this error msg (762529).
    According to this note, i need to upload a correction in funtion module which belongs to the software component
    BBPCRM release 4.0.
    I dont see this component in my system.
    My qwery is weather we need this component for SRM 5.0?
    if no, then how do we overcome the error msg?
    Thanx n Regards
    Abhishek Ganguly.

    Dear Friends,
    I am also faced this type of error in CRM 2007 SP5. I tried below steps and it is working.
    1. Type your inputs in R3AC1
    2. Press enter. System will thorugh error message as " Filter option '' is not possible for Object MATERIAL".
    3. Then, press ok.
    4. Go to debug mode. ie. enter /H in command field then press enter. Now, come to filler tab and press enter.
    6. Now, debug mode is switched on
    7. Set Break point at  CALL FUNCTION 'SMOFFILTAB_CHECK'  (ie. Main Program:SAPLSMOF_CUSTFB1 & source code of: SMOF_CUSTFB_FORM)
    8. Get into the function module.
    9. System checks the table "smoffiltab". If table is empty, system will through fillter option not possible error. If you are not maintained any fillter in MATERAL object, the table will be empty. so, now set value as "S" in lv_smoffiltab-filtersys variable.
    10. Now, system will accept your entry.
    I dont know, this method is right or wrong. But, it is working in CRM 2007.  In SRM you may also check it.
    Thanks & Regards,
    Rajagopal
    Chennai - INDIA.

  • How to set "Created By" field for KD Documents

    In our system documents that are entered to the Knowledge Directory are not tagged with who it was that submitted them.
    We would like to capture that information but I'm not sure how to enable it (or if its possible).
    I've looked at the Global Property Map and don't see a setting for a document, I looked at the Global Document Map but that seems to specifically relay info between the documents meta data and portal properties (which is not what I'm looking to do).
    Does anyone know how to attach the portal user in some type of "submitted/created by" field to a document?
    Thanks and happy September!

    Hello Keshav.T,
    Thank you for your information.
    Finally, I got an answer from OSS and the following is that.
    The popup is shown when there are more than 10 variants exist.
    If do not want to have this popup, you can modify the include
    LSVARTOP in SE38:
    C_VARILIST TYPE I VALUE '10' - maybe change value to '100'
    or if you want to have the popup but without the name inside:
    change include LSVARE01 and comment the line:
    ename-low = sy-uname. append ename. "old
    ename-low = sy-uname. append ename. "new
    I believe this message might be able to solve my problem.
    Thanks again.
    BR,
    Chris Kim

  • OBIEE filter/criteria limit for AND/OR operations for a report

    Hi
    We have a report that has around twenty "OR" criterias and ten "AND" criterias. All the filters are logically correct but report is returning invalid data. However if we reduce some filters then report works fine.
    Any ideas of increasing filters limit for a report or reason of the issue.
    Umer

    Thanks Chaknor,
    The report i created would not result any error code/msg.
    The only reason i put question here is:
    My report has around 50 predicates and is returning data without any respect of the predicates i have applied. However if i reduce some predicates (says reduce them to 20) then my report results correct data.
    For the time i tried a work around and created two reports using half of the predicates in one and half in two. but i need everything in one single report.
    The most important thing is that when i execute report with 50 predicates, the query i get in NQquery log omits many predicates.
    Following is what i get in NQquery log
    After removing half of the filters from the report the where clause from the log is given below;
    WHERE ( t120650.patient_seq_num = t120867.patient_seq_num
    AND t120585.location_seq_num = t120738.location_seq_num
    AND t120585.visit_seq_num = t120650.visit_seq_num
    AND t120585.provider_seq_num = t120767.provider_seq_num
    AND t120650.procedure_seq_num = t121446.procedure_seq_num
    AND t120738.practice = 'MSP'
    AND t120800.plan_category = 'CORNEL IPA'
    AND CASE
    WHEN t120650.charge_seq_num = t120650.parent_seq_num
    THEN 'NO'
    ELSE 'YES'
    END = 'NO'
    AND t120767.provider <> 'SANDH,OLD'
    AND t120767.provider <> 'GRANSR,OLD'
    AND t120767.provider <> 'GRANATO,SR'
    AND t120767.provider <> 'SANDHAUS,J'
    AND t120767.provider <> 'AARONS,OLD'
    AND t120767.provider <> 'DYBNER,OLD'
    AND t120767.provider <> 'GRANJR,OLD'
    AND t120767.provider <> 'AAR-DYBNER'
    AND t120767.provider <> 'SUBIETAS,A'
    AND t120767.provider <> 'TILLEM,OLD'
    AND t120767.provider <> 'WEBER,OLD'
    AND t120767.provider <> 'WOLGEL,C'
    AND (t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'HIPNY', 'NYBCEMP')
    AND ( t120800.insurance IN ('AETNA', 'HIPNY')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    AND ( t120800.insurance IN ('HIPNY')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'DYBNER,R', 'GRANATO,JR', 'TILLEM,S',
    'WEBER,M')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    AND ( t120800.insurance IN
    ('ACSHEALTHN', 'CIGNA', 'HIPNY', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'DYBNER,R', 'GRANATO,JR', 'TILLEM,S',
    'WEBER,M')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    AND ( t120767.provider IN
    ('AARONSON', 'DYBNER,R', 'GRANATO,JR', 'TILLEM,S',
    'WEBER,M')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    AND ( t120767.provider IN
    ('DYBNER,R', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    AND ( t120767.provider IN
    ('DYBNER,R', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON', 'DYBNER,R')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'DYBNER,R', 'GRANATO,JR', 'TILLEM,S',
    'WEBER,M')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    AND ( t120767.provider IN ('DYBNER,R')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN
    ('DYBNER,R', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('DYBNER,R')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('DYBNER,R')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON', 'DYBNER,R')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON', 'DYBNER,R')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('DYBNER,R')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN
    ('DYBNER,R', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120767.provider IN ('GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120767.provider IN
    ('AARONSON', 'GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120767.provider IN ('GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN ('ACSHEALTHN', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-08-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND ( t120767.provider IN ('AARONSON', 'DYBNER,R')
    OR t120800.insurance IN
    ('ACSHEALTHN', 'AETNA', 'CIGNA', 'NYBCEMP')
    OR t120585.visit_date >= TIMESTAMP '2011-01-01 00:00:00'
    AND ( t120767.provider IN ('GRANATO,JR', 'TILLEM,S', 'WEBER,M')
    OR t120800.insurance IN ('AETNA')
    OR t120585.visit_date >= TIMESTAMP '2010-04-01 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-04-20 00:00:00'
    OR t120585.visit_date >= TIMESTAMP '2010-10-01 00:00:00'
    AND t120767.provider <> 'WOLGEL,OLD'
    However when we increase the filters the where clause is truncated to;
    WHERE ( t120650.patient_seq_num = t120867.patient_seq_num
    AND t120585.location_seq_num = t120738.location_seq_num
    AND t120585.visit_seq_num = t120650.visit_seq_num
    AND t120585.provider_seq_num = t120767.provider_seq_num
    AND t120650.procedure_seq_num = t121446.procedure_seq_num
    AND t120738.practice = 'MSP'
    AND t120800.plan_category = 'CORNEL IPA'
    AND CASE
    WHEN t120650.charge_seq_num = t120650.parent_seq_num
    THEN 'NO'
    ELSE 'YES'
    END = 'NO'
    AND t120767.provider <> 'SANDH,OLD'
    AND t120767.provider <> 'GRANSR,OLD'
    AND t120767.provider <> 'GRANATO,SR'
    AND t120767.provider <> 'SANDHAUS,J'
    AND t120767.provider <> 'AARONS,OLD'
    AND t120767.provider <> 'DYBNER,OLD'
    AND t120767.provider <> 'GRANJR,OLD'
    AND t120767.provider <> 'AAR-DYBNER'
    AND t120767.provider <> 'SUBIETAS,A'
    AND t120767.provider <> 'TILLEM,OLD'
    AND t120767.provider <> 'WEBER,OLD'
    AND t120767.provider <> 'WOLGEL,C'
    Need help !

  • Getting and setting dynamic y-field for flex chart

    I'm pulling data from a amfphp service for
    a series of charts. My client now wants the the chart's fields to be label and display data dynamically so they can change the service with out breaking the charts.
    For example  {Month:"January", Flex:39, Flash:71.8, Photoshop:23.7},
    They'd like to be able to change the software names and the charts would still work without having to go into the code and change the yfield property.
    A code sample would be great. Thanks in advance.

    You can declare a bindable string variable that you can use as title in your axis:
    [Bindable]
    private var labelForAxis:String="";
    <mx:verticalAxis>
                    <mx:LinearAxis baseAtZero="false" title="{labelForAxis}" />
                </mx:verticalAxis>  
    Every time you change the string variable you label will also change.

  • F4 for Editable field in ALV, display Name but capture ID

    Hi Friends,
    I have a ALV for which i have defined a Structure, which is passed to Fieldcatlog.
    I have defined a Search help - ZUSER_NAME which has following fields to display.
    USERID - USR02-BNAME
    FNAME
    LNAME
    FULLNAME
    So my structure for fieldcatalog has User-id which is linked to this search help with Domain XUBNAME.
    So in my report i made this User-Id as editable and F4 available, everything is working fine.
    when user does a F4, its displaying Userid,Fname,Lname and complete name.upon selection and save i am capturing the id and storing in the ztable.
    But now i have a requirement that when user selects a value from this search help on F4, i need to display Fullname but capture the User Id. How can i do that?
    This is something similar to the one we have in BSP- key-value pair.
    how to do this in ALV.
    Appreciate if someone can guide me thru.
    Thanks,
    Simha
    Edited by: Simha on Sep 6, 2008 2:24 PM

    hai ,  this is example code for editing the F4 display .. check out this
    REPORT zalv_editf4display.
    *Type pools for alv
    TYPE-POOLS : slis.
    *structure for t582a tbale
    TYPES : BEGIN OF ty_table,
            infty TYPE infty,
            pnnnn TYPE pnnnn_d,
            zrmkz TYPE dzrmkz,
            zeitb TYPE dzeitb,
            dname TYPE dianm,
             davo TYPE davo,
            davoe TYPE davoe,
            END OF ty_table.
    *Structure for infotype text
    TYPES : BEGIN OF ty_itext,
            infty TYPE infty,
            itext TYPE intxt,
            sprsl TYPE sprsl,
            END OF ty_itext.
    *Structure for output display
    TYPES : BEGIN OF ty_output,
            infty TYPE infty,
            itext TYPE intxt,
            pnnnn TYPE pnnnn_d,
            zrmkz TYPE dzrmkz,
            zeitb TYPE dzeitb,
            dname TYPE dianm,
            davo TYPE davo,
            davoe TYPE davoe,
           END OF ty_output.
    *internal table and work area declarations
    DATA : it_table TYPE STANDARD TABLE OF ty_table INITIAL SIZE 0,
           it_output TYPE STANDARD TABLE OF ty_output INITIAL SIZE 0,
           it_pbo TYPE STANDARD TABLE OF ty_output INITIAL SIZE 0,
           it_ittext TYPE STANDARD TABLE OF ty_itext INITIAL SIZE 0,
           wa_table TYPE ty_table,
           wa_output TYPE ty_output,
           wa_ittext TYPE ty_itext.
    *Data declarations for dropdown lists for f4
    DATA: it_dropdown TYPE lvc_t_drop,
          ty_dropdown TYPE lvc_s_drop,
    *data declaration for refreshing of alv
          stable TYPE lvc_s_stbl.
    *Global variable declaration
    DATA: gstring TYPE c.
    *Data declarations for ALV
    DATA: c_ccont TYPE REF TO cl_gui_custom_container,         "Custom container object
          c_alvgd         TYPE REF TO cl_gui_alv_grid,         "ALV grid object
          it_fcat            TYPE lvc_t_fcat,                  "Field catalogue
          it_layout          TYPE lvc_s_layo.                  "Layout
    *ok code declaration
    DATA:
      ok_code       TYPE ui_func.
    *initialization event
    INITIALIZATION.
    *start of selection event
    START-OF-SELECTION.
    *select the infotypes maintained
      SELECT infty
              pnnnn
              zrmkz
              zeitb
              dname
              davo
              davoe
              FROM t582a UP TO 10 ROWS
              INTO CORRESPONDING FIELDS OF TABLE it_table.
    *Select the infotype texts
      IF it_table[] IS NOT INITIAL.
        SELECT itext
                 infty
                 sprsl
                 FROM t582s
                 INTO CORRESPONDING FIELDS OF TABLE it_ittext
                 FOR ALL ENTRIES IN it_table
                 WHERE infty = it_table-infty
                 AND sprsl = 'E'.
      ENDIF.
    *Apppending the data to the internal table of ALV output
      LOOP AT it_table INTO wa_table.
        wa_output-infty = wa_table-infty.
        wa_output-pnnnn = wa_table-pnnnn.
        wa_output-zrmkz = wa_table-zrmkz.
        wa_output-zeitb = wa_table-zeitb.
        wa_output-dname = wa_table-dname.
        wa_output-davo = wa_table-davo.
        wa_output-davoe = wa_table-davoe.
    For texts
        READ TABLE it_ittext INTO wa_ittext WITH KEY infty = wa_table-infty.
        wa_output-itext = wa_ittext-itext.
        APPEND wa_output TO it_output.
        CLEAR wa_output.
      ENDLOOP.
    Calling the ALV screen with custom container
      CALL SCREEN 0600.
    *On this statement double click  it takes you to the screen painter SE51.
    *Enter the attributes
    *Create a Custom container and name it CCONT and OK code as OK_CODE.
    *Save check and Activate the screen painter.
    *Now a normal screen with number 600 is created which holds the ALV grid.
    PBO of the actual screen ,
    Here we can give a title and customized menus
    *create 2 buttons with function code 'SAVE' and 'EXIT'.
    GIVE A SUITABLE TITLE
    *&      Module  STATUS_0600  OUTPUT
          text
    MODULE status_0600 OUTPUT.
      SET PF-STATUS 'DISP'.
      SET TITLEBAR 'ALVF4'.
    ENDMODULE.                 " STATUS_0600  OUTPUT
    calling the PBO module ALV_GRID.
    *&      Module  PBO  OUTPUT
          text
    MODULE pbo OUTPUT.
    *Creating objects of the container
      CREATE OBJECT c_ccont
           EXPORTING
              container_name = 'CCONT'.
    create object for alv grid
      create object c_alvgd
      exporting
      i_parent = c_ccont.
    SET field for ALV
      PERFORM alv_build_fieldcat.
    Set ALV attributes FOR LAYOUT
      PERFORM alv_report_layout.
      CHECK NOT c_alvgd IS INITIAL.
    Call ALV GRID
      CALL METHOD c_alvgd->set_table_for_first_display
        EXPORTING
          is_layout                     = it_layout
          i_save                        = 'A'
        CHANGING
          it_outtab                     = it_output
          it_fieldcatalog               = it_fcat
        EXCEPTIONS
          invalid_parameter_combination = 1
          program_error                 = 2
          too_many_lines                = 3
          OTHERS                        = 4.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                   WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    ENDMODULE.                 " PBO  OUTPUT
    *&      Form  alv_build_fieldcat
          text
         <--P_IT_FCAT  text
    *subroutine to build fieldcat
    FORM alv_build_fieldcat.
      DATA lv_fldcat TYPE lvc_s_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '1'.
      lv_fldcat-fieldname = 'INFTY'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 8.
      lv_fldcat-scrtext_m = 'Infotype'.
      lv_fldcat-icon = 'X'.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '2'.
      lv_fldcat-fieldname = 'PNNNN'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'Structure'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '3'.
      lv_fldcat-fieldname = 'ITEXT'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 60.
      lv_fldcat-scrtext_m = 'Description'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '5'.
      lv_fldcat-fieldname = 'ZRMKZ'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 1.
      lv_fldcat-scrtext_m = 'PERIOD'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '6'.
      lv_fldcat-fieldname = 'ZEITB'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 5.
      lv_fldcat-scrtext_m = 'Time constraint'.
      lv_fldcat-edit = 'X'.
    *To avail the existing F4 help these are to
    *be given in the field catalogue
      lv_fldcat-f4availabl = 'X'.
      lv_fldcat-ref_table = 'T582A'.
      lv_fldcat-ref_field = 'ZEITB'.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '7'.
      lv_fldcat-fieldname = 'DNAME'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'Dialogmodule'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '8'.
      lv_fldcat-fieldname = 'DAVO'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'Start'.
      lv_fldcat-edit = 'X'.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
      lv_fldcat-row_pos   = '1'.
      lv_fldcat-col_pos   = '9'.
      lv_fldcat-fieldname = 'DAVOE'.
      lv_fldcat-tabname   = 'IT_OUTPUT'.
      lv_fldcat-outputlen = 15.
      lv_fldcat-scrtext_m = 'End'.
      lv_fldcat-icon = ''.
      APPEND lv_fldcat TO it_fcat.
      CLEAR lv_fldcat.
    *To create drop down for the field 'DAVO'
    with our own f4 help
      ty_dropdown-handle = '1'.
      ty_dropdown-value = ' '.
      APPEND ty_dropdown TO it_dropdown.
      ty_dropdown-handle = '1'.
      ty_dropdown-value = '1'.
      APPEND ty_dropdown TO it_dropdown.
      ty_dropdown-handle = '1'.
      ty_dropdown-value = '2'.
      APPEND ty_dropdown TO it_dropdown.
      ty_dropdown-handle = '1'.
      ty_dropdown-value = '3'.
      APPEND ty_dropdown TO it_dropdown.
      CALL METHOD c_alvgd->set_drop_down_table
        EXPORTING
          it_drop_down = it_dropdown.
      LOOP AT it_fcat INTO lv_fldcat.
        CASE lv_fldcat-fieldname.
    To assign dropdown in the fieldcataogue
          WHEN 'DAVO'.
            lv_fldcat-drdn_hndl = '1'.
            lv_fldcat-outputlen = 15.
            MODIFY it_fcat FROM lv_fldcat.
        ENDCASE.
      ENDLOOP.
    ENDFORM.                    " alv_build_fieldcat
    *&      Form  alv_report_layout
          text
         <--P_IT_LAYOUT  text
    *Subroutine for setting alv layout
    FORM alv_report_layout.
      it_layout-cwidth_opt = 'X'.
      it_layout-col_opt = 'X'.
      it_layout-zebra = 'X'.
    ENDFORM.                    " alv_report_layout
    PAI module of the screen created. In case we use an interactive ALV or
    *for additional functionalities we can create OK codes
    *and based on the user command we can do the coding.
    *&      Module  PAI  INPUT
          text
    MODULE pai INPUT.
    *To change the existing values and refresh the grid
    *And only values in the dropdown or in the default
    *F4 can be given , else no action takes place for the dropdown
    *and error is thrown for the default F4 help and font changes to red
    *and on still saving, value is not changed
      c_alvgd->check_changed_data( ).
    *Based on the user input
    *When user clicks 'SAVE;
      CASE ok_code.
        WHEN 'SAVE'.
    *A pop up is called to confirm the saving of changed data
          CALL FUNCTION 'POPUP_TO_CONFIRM'
            EXPORTING
              titlebar       = 'SAVING DATA'
              text_question  = 'Continue?'
              icon_button_1  = 'icon_booking_ok'
            IMPORTING
              answer         = gstring
            EXCEPTIONS
              text_not_found = 1
              OTHERS         = 2.
          IF sy-subrc NE 0.
          MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                  WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
          ENDIF.
    *When the User clicks 'YES'
          IF ( gstring = '1' ).
            MESSAGE 'Saved' TYPE 'S'.
    *Now the changed data is stored in the it_pbo internal table
            it_pbo = it_output.
    *Subroutine to display the ALV with changed data.
            PERFORM redisplay.
          ELSE.
    *When user clicks NO or Cancel
            MESSAGE 'Not Saved'  TYPE 'S'.
          ENDIF.
    **When the user clicks the 'EXIT; he is out
        WHEN 'EXIT'.
          LEAVE PROGRAM.
      ENDCASE.
      CLEAR: ok_code.
    ENDMODULE.                 " PAI  INPUT
    *&      Form  REDISPLAY
          text
    -->  p1        text
    <--  p2        text
    FORM redisplay .
    *Cells of the alv are made non editable after entering OK to save
      CALL METHOD c_alvgd->set_ready_for_input
        EXPORTING
          i_ready_for_input = 0.
    *Row and column of the alv are refreshed after changing values
      stable-row = 'X'.
      stable-col = 'X'.
    *REfreshed ALV display with the changed values
    *This ALV is non editable and contains new values
      CALL METHOD c_alvgd->refresh_table_display
        EXPORTING
          is_stable = stable
        EXCEPTIONS
          finished  = 1
          OTHERS    = 2.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
               WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " REDISPLAY

  • BIP & trying to auto-set the current date for a parameter

    I'm trying to allow for a date selector as a parameter for one of my reports. This is BIP 11.1.1.5.
    I've set up a field for the parameter and can pass it into the report but want to see if I can auto-fill this field with today's date, and then set the Date From to today and the Date To to 3 days from now. Is this possible? Is there a way to do something like "format-date:sysdate('MM/dd/YYYY');" in these fields? I've attached an image of my fields in my Data Model.
    My image - http://goo.gl/mcXS7
    Thanks.
    Edited by: thejame on Jun 7, 2011 9:38 AM

    Thank You! I came across this before but never saw you have to use the {$ to get to the value.
    {$SYSDATE()$} gets me today's date.
    So can I use these in the BIP's Query Builder or other areas where I want to populate fields?
    Example: I want to use it in the actual report's parameters but it just comes across as "{$SYSDATE()$}"

  • To set HOTSPOT for a field in ALV-oops and when clecked should call transac

    Hi,
    I need to set HOTSPOT for a field in O/P list using ALV-oops and when clecked should take me to Transaction VA01. Please help....
    Thanks,
    Prabhu

    Hi,
         Please go through this code it may help u.
    REPORT zcls_alv_oops MESSAGE-ID z1.
    TABLES : mara.
    Types Declaration..\
    TYPES :
    BEGIN OF t_mara,
    matnr TYPE matnr,
    mtart TYPE mtart,
    maktx TYPE maktx,
    END OF t_mara,
    BEGIN OF t_marc,
    matnr TYPE matnr,
    werks TYPE werks_d,
    mtart TYPE mtart,
    maktx TYPE maktx,
    END OF t_marc.
    Internal Tables Declaration..\
    DATA :
    i_mara TYPE TABLE OF t_mara,
    i_marc TYPE TABLE OF t_marc,
    i_fcat1 TYPE lvc_t_fcat,
    i_fcat2 TYPE lvc_t_fcat.
    Constants Declaration..\
    CONSTANTS :
    c_cont1 TYPE scrfname VALUE 'CONT1',
    c_cont2 TYPE scrfname VALUE 'CONT2'.
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME.
    SELECT-OPTIONS:
    s_matnr FOR mara-matnr NO INTERVALS.
    SELECTION-SCREEN SKIP 1.
    PARAMETERS :
    p_hotspt RADIOBUTTON GROUP r1 DEFAULT 'X',
    p_bttn RADIOBUTTON GROUP r1.
    SELECTION-SCREEN END OF BLOCK b1.
    \* Class forward referncing.
    CLASS lcl_rcvr_class DEFINITION DEFERRED.
    \* Pointers Declaration..
    DATA :
    lp_rcvr TYPE REF TO lcl_rcvr_class,
    lp_cont1 TYPE REF TO cl_gui_custom_container,
    lp_cont2 TYPE REF TO cl_gui_custom_container,
    lp_grid1 TYPE REF TO cl_gui_alv_grid,
    lp_grid2 TYPE REF TO cl_gui_alv_grid.
    \* Local Class Definiton.
    CLASS lcl_rcvr_class DEFINITION.
    PUBLIC SECTION.
    METHODS :
    hotspot_click FOR EVENT hotspot_click OF cl_gui_alv_grid
    IMPORTING e_row_id e_column_id es_row_no,
    handle_double_click FOR EVENT double_click OF cl_gui_alv_grid
    IMPORTING e_row e_column.
    ENDCLASS.
    \* Local Class Implementation.
    CLASS lcl_rcvr_class IMPLEMENTATION.
    METHOD hotspot_click.
    DATA :
    wa_mara TYPE t_mara,
    wa_marc TYPE t_marc.
    DATA :
    l_index TYPE sy-tabix.
    READ TABLE i_mara INTO wa_mara INDEX e_row_id-index.
    IF sy-subrc EQ 0.
    REFRESH i_marc.
    SELECT matnr
    werks
    INTO TABLE i_marc
    FROM marc
    WHERE matnr EQ wa_mara-matnr.
    IF sy-subrc EQ 0.
    LOOP AT i_marc INTO wa_marc.
    l_index = sy-tabix.
    wa_marc-mtart = wa_mara-mtart.
    wa_marc-maktx = wa_mara-maktx.
    MODIFY i_marc FROM wa_marc INDEX l_index
    TRANSPORTING mtart maktx.
    ENDLOOP.
    CALL SCREEN 200.
    ELSE.
    MESSAGE e121 WITH text-005 wa_mara-matnr.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    METHOD handle_double_click.
    DATA :
    wa_mara TYPE t_mara,
    wa_marc TYPE t_marc.
    DATA :
    l_index TYPE sy-tabix.
    READ TABLE i_mara INTO wa_mara INDEX e_row-index.
    IF sy-subrc EQ 0.
    REFRESH i_marc.
    SELECT matnr
    werks
    INTO TABLE i_marc
    FROM marc
    WHERE matnr EQ wa_mara-matnr.
    IF sy-subrc EQ 0.
    LOOP AT i_marc INTO wa_marc.
    l_index = sy-tabix.
    wa_marc-mtart = wa_mara-mtart.
    wa_marc-maktx = wa_mara-maktx.
    MODIFY i_marc FROM wa_marc INDEX l_index
    TRANSPORTING mtart maktx.
    ENDLOOP.
    CALL SCREEN 200.
    ELSE.
    MESSAGE e121 WITH text-005 wa_mara-matnr.
    ENDIF.
    ENDIF.
    ENDMETHOD.
    ENDCLASS.
    \* Start of Selection
    START-OF-SELECTION.
    \* Extract the Material Master data for the Input Material.
    SELECT a~matnr
    a~mtart
    b~maktx
    INTO TABLE i_mara
    FROM mara AS a
    INNER JOIN makt AS b
    ON a~matnr EQ b~matnr
    WHERE a~matnr IN s_matnr
    AND b~spras EQ sy-langu.
    END-OF-SELECTION.
    IF NOT i_mara\[\] IS INITIAL.
    \* Call Screen to display the Material Master data.
    CALL SCREEN 100.
    ELSE.
    MESSAGE s121 WITH text-006.
    ENDIF.
    \*& Module DISP_GRID OUTPUT
    \* text
    MODULE disp_grid OUTPUT.
    \* Build the Field catelog for Material Master data.
    PERFORM build_fcat.
    \* Display the Material Master data using ALV.
    PERFORM disp_alv.
    ENDMODULE. " DISP_GRID OUTPUT
    \*& Module USER_COMMAND_0100 INPUT
    \* text
    MODULE user_command_0100 INPUT.
    \*when exit or cancel is clicked program has to come out
    CASE sy-ucomm.
    WHEN 'EXIT' OR 'CANC'.
    LEAVE PROGRAM.
    WHEN 'BACK'.
    LEAVE TO SCREEN 0.
    ENDCASE.
    ENDMODULE. " USER_COMMAND_0100 INPUT
    \*& Form build_fcat
    \* text
    \* \--> p1 text
    \* <-\- p2 text
    FORM build_fcat.
    DATA : ws_fcat TYPE lvc_s_fcat.
    ws_fcat-fieldname = 'MATNR'.
    ws_fcat-scrtext_m = text-001.
    ws_fcat-tabname = 'I_MARA'.
    IF p_hotspt EQ 'X'.
    ws_fcat-hotspot = 'X'.
    ENDIF.
    APPEND ws_fcat TO i_fcat1.
    CLEAR ws_fcat.
    ws_fcat-fieldname = 'MTART'.
    ws_fcat-scrtext_m = text-002.
    ws_fcat-tabname = 'I_MARA'.
    APPEND ws_fcat TO i_fcat1.
    CLEAR ws_fcat.
    ws_fcat-fieldname = 'MAKTX'.
    ws_fcat-scrtext_m = text-003.
    ws_fcat-tabname = 'I_MARA'.
    APPEND ws_fcat TO i_fcat1.
    CLEAR ws_fcat.
    ENDFORM. " build_fcat
    \*& Form disp_alv
    \* text
    \* \--> p1 text
    \* <-\- p2 text
    FORM disp_alv.
    IF lp_cont1 IS INITIAL.
    \* Create the Container Object of Material Master.
    CREATE OBJECT lp_cont1
    EXPORTING
    container_name = c_cont1
    EXCEPTIONS
    cntl_error = 1
    cntl_system_error = 2
    create_error = 3
    lifetime_error = 4
    lifetime_dynpro_dynpro_link = 5
    others = 6 .
    IF sy-subrc NE 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ELSE.
    \* Create the Object for Grid of Material Master.
    CREATE OBJECT lp_grid1
    EXPORTING
    i_parent = lp_cont1
    EXCEPTIONS
    error_cntl_create = 1
    error_cntl_init = 2
    error_cntl_link = 3
    error_dp_create = 4
    others = 5.
    IF sy-subrc NE 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ELSE.
    \* Dipslay Material Master data by calling method.
    CALL METHOD lp_grid1->set_table_for_first_display
    CHANGING
    it_outtab = i_mara
    it_fieldcatalog = i_fcat1
    EXCEPTIONS
    invalid_parameter_combination = 1
    program_error = 2
    too_many_lines = 3
    OTHERS = 4.
    IF sy-subrc NE 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ELSE.
    \* Set Handler for the Hot Spot Event.
    CREATE OBJECT lp_rcvr.
    IF p_hotspt EQ 'X'.
    SET HANDLER lp_rcvr->hotspot_click FOR lp_grid1.
    ELSE.
    SET HANDLER lp_rcvr->handle_double_click FOR lp_grid1.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDFORM. " disp_alv
    \*& Module STATUS_0100 OUTPUT
    \* text
    MODULE status_0100 OUTPUT.
    SET PF-STATUS 'MAIN_STAT'.
    SET TITLEBAR 'T_100'.
    ENDMODULE. " STATUS_0100 OUTPUT
    \*& Module STATUS_0200 OUTPUT
    \* text
    MODULE status_0200 OUTPUT.
    SET PF-STATUS 'PLANT_STAT'.
    SET TITLEBAR 'T_200'.
    ENDMODULE. " STATUS_0200 OUTPUT
    \*& Module DISP_GRID_plant OUTPUT
    \* text
    MODULE disp_grid_plant OUTPUT.
    \* Build the Field catelog for Material Plant data.
    PERFORM build_fcat_plant.
    \* Display the Material Master Plant data using ALV.
    PERFORM disp_alv_plant.
    ENDMODULE. " DISP_GRID_plant OUTPUT
    \*& Module USER_COMMAND_0200 INPUT
    \* text
    MODULE user_command_0200 INPUT.
    \*when exit or cancel is clicked program has to come out
    CASE sy-ucomm.
    WHEN 'EXIT' OR 'CANC'.
    LEAVE PROGRAM.
    WHEN 'BACK'.
    LEAVE TO SCREEN 0.
    ENDCASE.
    ENDMODULE. " USER_COMMAND_0200 INPUT
    \*& Form build_fcat_plant
    \* text
    \* \--> p1 text
    \* <-\- p2 text
    FORM build_fcat_plant.
    DATA : ws_fcat TYPE lvc_s_fcat.
    ws_fcat-fieldname = 'MATNR'.
    ws_fcat-scrtext_m = text-001.
    ws_fcat-tabname = 'I_MARC'.
    APPEND ws_fcat TO i_fcat2.
    CLEAR ws_fcat.
    ws_fcat-fieldname = 'WERKS'.
    ws_fcat-scrtext_m = text-004.
    ws_fcat-tabname = 'I_MARC'.
    APPEND ws_fcat TO i_fcat2.
    CLEAR ws_fcat.
    ws_fcat-fieldname = 'MTART'.
    ws_fcat-scrtext_m = text-002.
    ws_fcat-tabname = 'I_MARC'.
    APPEND ws_fcat TO i_fcat2.
    CLEAR ws_fcat.
    ws_fcat-fieldname = 'MAKTX'.
    ws_fcat-scrtext_m = text-003.
    ws_fcat-tabname = 'I_MARC'.
    APPEND ws_fcat TO i_fcat2.
    CLEAR ws_fcat.
    ENDFORM. " build_fcat_plant
    \*& Form disp_alv_plant
    \* text
    \* \--> p1 text
    \* <-\- p2 text
    FORM disp_alv_plant.
    IF lp_cont2 IS INITIAL.
    \* Create the Container Object of Material Plant data.
    CREATE OBJECT lp_cont2
    EXPORTING
    container_name = c_cont2
    EXCEPTIONS
    cntl_error = 1
    cntl_system_error = 2
    create_error = 3
    lifetime_error = 4
    lifetime_dynpro_dynpro_link = 5
    others = 6.
    IF sy-subrc NE 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ELSE.
    \* Create the Object for Grid of Material Plant data.
    CREATE OBJECT lp_grid2
    EXPORTING
    i_parent = lp_cont2
    EXCEPTIONS
    error_cntl_create = 1
    error_cntl_init = 2
    error_cntl_link = 3
    error_dp_create = 4
    others = 5.
    IF sy-subrc NE 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ELSE.
    \* Dipslay Material Plant data by calling method.
    CALL METHOD lp_grid2->set_table_for_first_display
    CHANGING
    it_outtab = i_marc
    it_fieldcatalog = i_fcat2
    EXCEPTIONS
    invalid_parameter_combination = 1
    program_error = 2
    too_many_lines = 3
    OTHERS = 4.
    IF sy-subrc NE 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
    ENDIF.
    ENDIF.
    ELSE.
    \* Call method 'REFRESH_TABLE_DISPLAY' to refresh the grid data.
    CALL METHOD lp_grid2->refresh_table_display.
    ENDIF.
    ENDFORM. " disp_alv_plant

  • CRM 7.0 = ECC 6.0 Upload: Filter criteria for BUPA_MAIN

    Dear Experts,
    concerning filtering of BUPA_MAIN in CRM 7.0 => ECC 6.0 Upload we have already learned from SAP (to our surprise) that the only way is to redefine publication BUPA_MAIN as "simple intelligent" (Standard is simple bulk). BUPA_MAIN as "simple intelligent" offers a couple of fields (e.g. partner_no, is_customer) which can be defined as filter criteria.
    We have the requirement to filter by a bp status field which is not part of this set. By the way, we expected the filtering in object management (TX R3AC1, filters are only valid for ECC=>CRM Dowload) or at least in the TX CRMC_BUT_CALL_FU by registrating a ZFunction module in CRM outbound for BUPA_MAIN. Under certain circumstances the later leads to errors  in the subsequent middleware processing.
    Has anybody a similiar requirement or does face the same problems?
    Thanks for your help.
    Regards, Mark

    Hi Mark
    Please put this request in the correct forum of CRM Middleware.
    I am sure your will get the right help from the middleware experts.
    Regards

  • Problem in ALV set filter option

    Hi to all
    I have an issue regarding ALV report :
    I have developed an ALV report and it is showing report output correctly as required.
    when I further filter it on a particular field using SET FILTER OPTION , the length of the field is shorter than displayed.
    Why this happens so.
    BUT for the same field in a standard ALV report , it shows the same length as displayed in report.
    Please advice. As this is the standard ALV functionality.
    Thanks & Regards
    Anubhav gupta

    Hi Gupta,
    <li>Define layout structure
    data: wa_layout   TYPE slis_layout_alv.
    <li>Pass value like below
      wa_layout-colwidth_optimize = 'X'.
    <li>Pass this structure through fm
        CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
             EXPORTING
                  i_callback_program = program
                  it_fieldcat        = it_fieldcat
                  is_layout          = wa_layout
                  it_events          = it_events
             TABLES
                  t_outtab           = i_mard.
    Thanks
    Venkat.O

  • GWI: Add new filter criteria for replication object BUPA_MAIN

    Hello,
    we are currently setting up Groupware Integration with CRM 7.0 and Outlook Exchange 2007. We would like to filter the BPs that are replicated to Outlook's public folder. The replication object BUPA_MAIN in Tx. SMOEAC has only got the following criteria fields:
    BPARTNER
    CENTRALARCHIVINGFLAG
    COUNTRYISO
    INDUSTRY
    IS_COMPETITOR
    IS_CONSUMER
    IS_CUSTOMER
    IS_DELETED
    IS_PROSPECT
    PARTNEREXTERNAL
    REGION
    SEARCHTERM1
    SEARCHTERM2
    SITE_ID
    We don't want to use any of those but would like to set a filter on BP Role and filter for all Groupware Employees. Only those should be replicated.
    We did set the filter conditions in customizing under "Filter Condition for Business Partners Exchange with Groupware" in order to replicate only BP with role GWEMP but still during Initial Load all Business Partners were replicated.
    Could anyone tell me how to avoid this?
    I hear it's possible to add new criteria fields to the replication object BUPA_MAIN.
    Could anyone tell me how this is done?
    Your help will be much appreciated.
    Thanks in advance!
    Angela

    Hello Angela
    Usually the settings under "Filter Condition for Business Partners Exchange with Groupware" should be enough to avoid the synchronization. With those settings all BP are filtered out except the ones with role GWEMP (Groupware Employee).
    We have the following setting in SPRO:
    BUPA     1     BUP001           X     X     
    BUPA     1     BUP003           X     X     
    BUPA     2        X     X
    BUPA     3                     X     X
    (first column empty, second and third column with X, last column empty).
    Regards
    Marco

Maybe you are looking for

  • Approve and reject button not appearing in the POrtal screen

    Hi All , I have an issue where i create a meeting rwquets and then it goes for approval to the manager , but in this case the manager is not able to see the approve and reject button in the screen , whereas it appears in the back end , please suggest

  • Payment cards settlement

    hia every body can anybody tell me how to see the settlement document after working with FCC1 is there any transaction code? please help me out thank you

  • 2LIS_02_ITM enhancement & delta initialization

    Hi gurus, i have enhanced 2LIS_02_ITM. In EKKO & EKPO table there are data: when i run the initialization package, no data are extracted. What is the problem? Thanks in advance! Bye Nando

  • UNABLE TO MAKE GR

    Hi Gurus, I created a purchase order for a particular quantity of 15000 No.s and after that when GR is made using MIGO trans code system displays "Document xxxxxxx does not contain any selectable items". Although the PO is made fresh, why GR is not a

  • Dynamic reporting, time dependent columns

    Hello, We are trying to make some dynamic reports, for example with the columns: the last six months , quarter, current year, last year etc etc (a half year report). Is it possible to give in a year\period which is the "current period", so that all d