BAPI_CUSTOMER_FIND search by KNA1-KUNNR

Hi all,
I'm experiencing strange behavior of BAPI_CUSTOMER_FIND while I base my search by KNA1-KUNNR. I provide following input parameters to the BAPI:
SELOPT_TAB-TABNAME       =                  KNA1
SELOPT_TAB-FIELDNAME    =                 KUNNR
SELOPT_TAB-FIELDVALUE   =                 1900
1900 is my customer number. I would expect that such a call as per parameters above should return all data about that customer.
Instead I'm getting message: No customer found for this selection in RESULT_TAB-MESSAGE field.
I'm able to see all the data in TA XD03 and also in table KNA1.
Can you advise how to use BAPI_CUSTOMER_FIND in order ot search by customer number?
thanks a lot!
m./

Try to pass values in internal format 1900 -> 0000001900, remenber SAP transactions, SE37 test and SE16(n) byt defualt use conversion-exit of the domain associated to field (here ALPHA, try to call CONVERSION_EXIT_ALPHA_INPUT).
COMP
TABNAME
FIELDNAME
FIELDVALUE
CUSTOMER
P
P
D
D
T
ID
NUM
KNA1
KUNNR
0000101562
101562
S
FN
800
found
KNA1
KUNNR
101560
W
FN
65
Not found
Regards,
Raymond

Similar Messages

  • Missing select-options for kna1-kunnr

    Hi,
    Has anybody ever come across this before ?
    I've modified a program to add a new select options for kna1-kunnr and added a bit of code that processes the value entered.
    In "development" it all tested OK and the program was transported up to "test".
    In "test" the users tested and everything was OK.
    The program was eventually transported up to "production" but when I run it in production the select-options for kna1-kunnr does not appear on the selection screen ? However, the when I run the program the additional bit of code that I also included does actually execute.
    I haven't been able to look at the code yet because SE38 and SE80 are disabled in "production".
    It sounds to me that the selection screen has somehow not generated correctly when the program was transported into production but the transport logs didn't display any errors or warnings. I have also had the program retransported into production but I still can't see the select-options.
    There are no variants for the program and I'm not getting any security issues on the SU53.
    Any help would be gratefully received.
    Thanks
    Stan

    Hi,
    You can try system->staus->program name. Double click on program name and see if you enter abap editor. You can check your code there.
    Or else just create another transport in development and send to production
    Thanks,

  • Search Help for KUNNR, depending on a certain BUKRS

    Hy gurus,
    I have the following selection-screen
    PARAMETERS    : p_bukrs  LIKE bsid-bukrs OBLIGATORY.
    SELECT-OPTIONS: s_kunnr  FOR  bsid-kunnr.
    I'd like to make the search help of KUNNR dependable on the
    input of p_bukrs.
    I don't want to create any self/made search help ,I need to use the standard one.
    F4IF_INT_TABLE_VALUE_REQUEST doesn't seem to be proper to my purpose...
    Thanx
    Christian

    Use SE11> select search help exit radio button> enter DEBI and display--> in the definition tab u can see this.
    Please see this link for overview
    http://www.sapdevelopment.co.uk/dictionary/shelp/shelp_exit.htm

  • Search help for Kunnr ( Customer Number )

    Hi Gurus,
    I have created select option with data element/field - KUNNR.
    But when i do an f4 help ..it prompts me for an search help but when i do enter..
    it does not give me kunnr values..it gives me the following error message:
    Select exactly one row in the value list to copy the value  
    Kindly suggest..
    Best Regards,
    Navin Fernandes.

    Hi,
    May be you need  to  select the particular row and the click on  OK.
    Priya
    Edited by: Chaitanya Priya Puvvada on Jan 27, 2010 1:21 PM

  • Logical Database DDF - GET KNA1 - change KUNNR to another customer....

    Hi
    Question 1a:
    When using logical database DDF I perform a GET KNA1 a check is performed in order to see if customer should be within selection or not. In some cases this customer refers to another customer (fiscal address) that should be used instead.
    So Customer KNA1-KUNNR: 123 should instead be Customer 456 which contains the relevant data for the next step in the selections from the logical database.
    ..GET KNB1
    ..GET BSID...
    How is it possible to replace customer 123 with customer 456 so the continous processing of the logical database will use the new customer number instead.
    Question 1b
    And a follow up question - If there is a solution to question above....
    How can I make sure that IF customer 456 pops up in the regular selection from the logical database - It is excluded since it was already used (when customer 123 was replaced with 456 above)...
    Best regards
    Henrik

    Hi Ranganath!
    Thankyou for looking into my problem.
    Ranganath Ramesh wrote:
    ...If you want to do something like that then you need to manually populate the customer numbers which are related to the selection screen field....
    Could you please clarify how I manually could add this new customer number to my selection screen field...whithout disturbing the origianal selection with GET KNA1 - at the same time as the CHECK-statement for my old customer number fails and is excluded from the selection.
    BR
    Henrik

  • Creation of search help manually fro select-options

    hi friends i got a requirement for creating the search helps manually for select-options.
    but i am facing a progbalem.
    i am attaching a sample code for what i have written for select-opions low of which when i am pressing f4 button i am getting list of data but when i am selecting that particular it is not withstading on the screen...kindly help in this regard very urguent..plz...all answers are rewarded..
    tableS: kna1.
    datA: BEGIN OF ITAB OCCURS 1,
        KUNNR TYPE KNA1-KUNNR,
        END OF ITAB.
    data: kunnr type kunnr.
    select-options: cust for kunnr .
    at selection-screen on value-request for cust-low.
    select kunnr from kna1 into table itab .
    CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
      EXPORTING
    *   DDIC_STRUCTURE      = ''
        RETFIELD               = 'CUST-LOW'
    *   PVALKEY                = ' '
    *   DYNPPROG               = ' '
    *   DYNPNR                 = ' '
    *   DYNPROFIELD            = ''
    *   STEPL                  = 0
    *   WINDOW_TITLE           =
       VALUE                  = 'CUST-LOW'
       VALUE_ORG              = 'S'
    *   MULTIPLE_CHOICE        = ' '
    *   DISPLAY                = 'X'
       CALLBACK_PROGRAM       = SY-CPROG
    *   CALLBACK_FORM          = ' '
    *   MARK_TAB               =
    * IMPORTING
    *   USER_RESET             =
      TABLES
        VALUE_TAB              = ITAB
    *   FIELD_TAB              =
    *   RETURN_TAB             =
    *   DYNPFLD_MAPPING        =
    * EXCEPTIONS
    *   PARAMETER_ERROR        = 1
    *   NO_VALUES_FOUND        = 2
    *   OTHERS                 = 3
    IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

    Hai  Saslove,
    I think Problem Lies In this Area When U r Creating   Search Helps.
    Import and Export Parameters
    When an input help is called, the entries that the user already made in the input template are taken into consideration. For example, if a user calls the input help for the flight number and already specified the carrier, of course only the numbers of flights of this carrier should be offered.
    On the other hand, if the user selects one row of the hit list, more than one field of the input template might have to be filled with data from the selected row of the hit list. For example, if the flight number is obtained from the hit list, the city of departure and the destination should also be returned in the screen template.
    The interface of a search help defines the context data that can be used in the input help and the data that can be returned in the input template.
    A parameter of a search help can be classified as:
    Import parameters: Parameters with which context information from the processed input template (screen) may be copied to the help process.
    Export parameters: Parameters with which values from the hit list may be returned to the input template.
    A parameter can simultaneously be an input and an export parameter. A search help can also contain parameters that are neither import nor export parameters. Such parameters could be required for the internal input help process, for example.
    When you attach a search help, you must define where the import parameters of the search help get their values from and the fields in which the contents of the export parameters are returned. See also Value Transport for Input Helps.
    Regards.
    Eshwar.

  • Need to change the Sort field(kna1-sortl) value

    Hi All,
    We have the requirement to fill the Search Term   (kna1-sortl) based the accounting group and 'kunnr' value.
    I.e as per the legacy system number range in brazil we need fill the sortl field based on accoung goup by concating the kunnr value to it.
    for Ex: 2GXXXXX0 this number need to filled in sortl field.
    where 'X' is repplaced by kunnr value.'2' and '0' are the constant values.Based on accounting group after value '2' we need to add either 'g' or  'S'.
    We find one user exit 'EXIT_SAPMF02D_001' but which does not contain the kna1 as the change perameter.
    kindly help me on it .if there is any other badi

    Hi,
    There is no std user-exit for this (at least we haven't found it as well).
    We have created implicit enhancement point implementation athe the end of form AUFRUF_USER_EXIT in include MF02DFEX.
    The code should be similiar to following:
    ENHANCEMENT 1  YEDSD_EO_ADD_DOC_PREFIX.    "active version
        DATA:
          ltp_doc_prefix TYPE y_dt_docpref.
    *--only in creation and change mode
        IF T020-AKTYP = 'H' OR
           T020-AKTYP = 'V'.
          CONCATENATE kna1-ktgrd kna1-kunnr INTO ltp_doc_prefix.
          kna1-yydocpre = ltp_doc_prefix.
        ENDIF.
    ENDENHANCEMENT.
    Regards,
    Marcin

  • Using ALV as a search Help

    Has anyone used ALV as a search help presentation/selection method.  I'm thinking, in a simplistic sense, it would be just creating an itab and presenting it on a grid in a container on a new screen called by an exit....
    Probably too simple, huh?    Pointers to any snippets that implement this would be welcome. 
    (additionally, might have a need to save user layouts of this info as well)
    Thoughts, comments, pitfalls.... ?
    Thanks...
    ...Mike

    Hey Michael a working example I just made for some1
    thought u might be interested
    Q. i_checkbox_fieldname = 'CHECKBOX'
    A. If the table output in the popup has checkboxes at the beginning of the rows (e.g. for multiple selection), the internal table must contain a field containing the value of the checkbox.
    Assign the name of this field to the parameter I_CHECKBOX_FIELDNAME.
    Q. i_tabname = 'TLINE'
    A.  This is the name of ur input help internal table
    Q. it_fieldcat = fieldcat[]
    A  The table u gonna display has to have a fieldcat.
    Q. it_excluding = extab[].
    A. In case u wanna exclude some functions.
    Below is a working example, paste it in se38 and activate.
    !!! Warning SAVE IT AS A LOCAL OBJECT !!!
    report ztests1.
    type-pools: slis.
    data: index type i.
    data: l_kunnr like kna1-kunnr.
    data: input(10) type c,
           text(4) type c,
           text1(5) type c.
    data: begin of itab occurs 10,
           kunnr like kna1-kunnr,
           name1 like kna1-name1,
          end of itab.
    data: e_exit.
    data: fieldcat TYPE slis_t_fieldcat_alv WITH HEADER LINE.
    parameter: p_kunnr(10) type c.
    at selection-screen on value-request for p_kunnr.
      select kunnr name1 up to 10 rows
        from kna1
        into table itab.
      fieldcat-tabname = 'ITAB'.
      fieldcat-fieldname = 'KUNNR'.
      fieldcat-seltext_m = 'Cust'.
      fieldcat-ddictxt = 'M'.
      fieldcat-outputlen = 10.
      APPEND fieldcat.
      CLEAR fieldcat.
      fieldcat-tabname = 'ITAB'.
      fieldcat-fieldname = 'NAME1'.
      fieldcat-seltext_m = 'Cust Name'.
      fieldcat-ddictxt = 'M'.
      fieldcat-outputlen = 30.
      APPEND fieldcat.
      CLEAR fieldcat.
        CALL FUNCTION 'REUSE_ALV_POPUP_TO_SELECT'
          EXPORTING
            I_TITLE                       = 'Customer Selection'
          I_SELECTION                   = 'X'
          I_ALLOW_NO_SELECTION          =
          I_ZEBRA                       = ' '
          I_SCREEN_START_COLUMN         = 0
          I_SCREEN_START_LINE           = 0
          I_SCREEN_END_COLUMN           = 0
          I_SCREEN_END_LINE             = 0
          I_CHECKBOX_FIELDNAME          =
          I_LINEMARK_FIELDNAME          =
          I_SCROLL_TO_SEL_LINE          = 'X'
            i_tabname                     = 'ITAB'
          I_STRUCTURE_NAME              =
            IT_FIELDCAT                   = fieldcat[]
          IT_EXCLUDING                  =
          I_CALLBACK_PROGRAM            =
          I_CALLBACK_USER_COMMAND       =
          IS_PRIVATE                    =
          IMPORTING
          ES_SELFIELD                   =
            E_EXIT                        = e_exit
          tables
            t_outtab                      = itab
        EXCEPTIONS
          PROGRAM_ERROR                 = 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.

  • Wt parameters to pass in  function module for particular kunnr fld

    wt parameters to pass in  function module f4if_int_table_value_request which is mostly preferred in reports instead of search help
    for eg i use select-options s_kunnr for kna1-kunnr & prepare i internal table it_kna1.
    den how 2 pass s_kunnr fld & it_kna1 in dat above FM for creating f4 functionality for particular s_kunnr fld on selection-screen.
    plz send me d code urgently

    Check below code....
      SELECT carrid carrname
                    FROM scarr
                    INTO CORRESPONDING FIELDS OF TABLE itab_carrid.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
           EXPORTING
                retfield        = 'CARRID'
                value_org       = 'S'
           TABLES
                value_tab       = itab_carrid
           EXCEPTIONS
                parameter_error = 1
                no_values_found = 2
                OTHERS          = 3.
      IF sy-subrc <> 0.
      ENDIF.

  • HELP SEARCH

    Hi!
    The problem is:
    I've created a HELP SEARCH for a field in a dynpro based on the T5ITQN, but when a user click on the matchcode, he must see only certain records of the table T5ITQN (this depends only by the "type" of user) and not all the records in the T5ITQN. How i can do this?
    Thanks for the answers.

    Instead you can try this solution -
    TYPES: BEGIN OF ztable,
             numde(20),
             kunnr(10).
    TYPES: END OF ztable.
    DATA: i_ztable TYPE ztable OCCURS 0 WITH HEADER LINE.
    DATA: v_choice TYPE i.
    PARAMETERS: p_kunnr LIKE kna1-kunnr DEFAULT '4290'.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_kunnr.
      i_ztable-numde = 'JOHN05001'.
      i_ztable-kunnr = '1'.
      APPEND i_ztable.
      CLEAR i_ztable.
      i_ztable-numde = 'PETE05001'.
      i_ztable-kunnr = '2'.
      APPEND i_ztable.
      CLEAR i_ztable.
      i_ztable-numde = 'JOHN05002'.
      i_ztable-kunnr = '1'.
      APPEND i_ztable.
      CLEAR i_ztable.
      i_ztable-numde = 'PETE05002'.
      i_ztable-kunnr = '2'.
      APPEND i_ztable.
      CLEAR i_ztable.
      CALL FUNCTION 'POPUP_WITH_TABLE_DISPLAY'
           EXPORTING
                endpos_col   = 50
                endpos_row   = 20
                startpos_col = 1
                startpos_row = 1
                titletext    = 'Test'
           IMPORTING
                choise       = v_choice
           TABLES
                valuetab     = i_ztable
           EXCEPTIONS
                break_off    = 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.
      ELSE.
        CLEAR i_ztable.
        READ TABLE i_ztable INDEX v_choice.
        MOVE i_ztable-kunnr TO p_kunnr.
      ENDIF.

  • Elementary Search help with distinct values. Kindly help!

    Hi Experts,
        I have to create a search help for Plant field. The Plant field is in a custom table YPLANT_DET. Unfortunately the plant field in this table is not unique.
    So the elementary search help will show duplicate plant entries.
    How to customize the elementary search help so that I get only distict values on F4 help?
    KIndly help!
    Thanks
    Gopal

    Hi,
    You need to use Search help exit...
    i am attaching below sample code..write the select query at appropriate location and pass the internal table to sub FM mentioned in the code..
    Code Sample
    BEGIN OF CODE SAMPLE -
    BEGIN OF INCLUDE LZSHLPTOP -
    FUNCTION-POOL zshlp. "MESSAGE-ID ..
    TYPE-POOLS shlp.
    TYPES:
    BEGIN OF t_knvp,
    kunnr TYPE kna1-kunnr,
    name1 TYPE kna1-name1,
    ort01 TYPE ort01_gp,
    stras TYPE stras_gp,
    kunn2 TYPE knvp-kunn2,
    name1_2 TYPE kna1-name1,
    END OF t_knvp.
    DATA: i_knvp TYPE TABLE OF t_knvp,
    wa_knvp TYPE t_knvp,
    wa_selopt TYPE ddshselopt,
    wa_fielddescr TYPE dfies.
    DATA:
    rc TYPE i,
    v_tabix LIKE sy-tabix.
    RANGES: r_ktokd FOR kna1-ktokd,
    r_mcod1 FOR kna1-name1,
    r_sortl FOR kna1-sortl,
    r_kunnr FOR kna1-kunnr,
    r_ort01 FOR kna1-ort01.
    END OF INCLUDE LZSHLPTOP -
    BEGIN OF FUNCTION MODULE Z_CUSTOM_SEARCH -
    FUNCTION z_custom_search.
    ""Local interface:
    *" TABLES
    *" SHLP_TAB TYPE SHLP_DESCR_TAB_T
    *" RECORD_TAB STRUCTURE SEAHLPRES
    *" CHANGING
    *" VALUE(SHLP) TYPE SHLP_DESCR_T
    *" VALUE(CALLCONTROL) LIKE DDSHF4CTRL STRUCTURE DDSHF4CTRL
    EXIT immediately, if you do not want to handle this step
    CASE callcontrol-step.
    STEP SELECT (Select values)
    This step may be used to overtake the data selection completely.
    To skip the standard seletion, you should return 'DISP' as following
    step in CALLCONTROL-STEP.
    Normally RECORD_TAB should be filled after this step.
    WHEN 'SELECT'.
    Change column header texts appearing on the search help hit list
    LOOP AT shlp-fielddescr INTO wa_fielddescr.
    v_tabix = sy-tabix.
    CASE wa_fielddescr-fieldname.
    WHEN 'KUNNR'.
    wa_fielddescr-fieldtext = 'ShipToCustomer#'.
    wa_fielddescr-reptext = 'ShipToCustomer#'.
    wa_fielddescr-scrtext_s = 'ShipTo #'.
    wa_fielddescr-scrtext_m = 'ShipToCustomer#'.
    wa_fielddescr-scrtext_l = 'ShipToCustomer#'.
    MODIFY shlp-fielddescr FROM wa_fielddescr
    INDEX v_tabix TRANSPORTING fieldtext reptext scrtext_s
    scrtext_m scrtext_l.
    WHEN 'KUNN2'.
    wa_fielddescr-reptext = 'BillToCustomer#'.
    wa_fielddescr-fieldtext = 'BillToCustomer#'.
    wa_fielddescr-scrtext_s = 'BillTo #'.
    wa_fielddescr-scrtext_m = 'BillToCustomer #'.
    wa_fielddescr-scrtext_l = 'BillToCustomer #'.
    MODIFY shlp-fielddescr FROM wa_fielddescr
    INDEX v_tabix TRANSPORTING fieldtext reptext scrtext_s
    scrtext_m scrtext_l.
    WHEN 'NAME1'.
    wa_fielddescr-fieldtext = 'ShipToCustomer Name'.
    wa_fielddescr-reptext = 'ShipToCustomer Name'.
    wa_fielddescr-scrtext_s = 'ShipTo Name'.
    wa_fielddescr-scrtext_m = 'ShipToCustomer Name'.
    wa_fielddescr-scrtext_l = 'ShipToCustomer Name'.
    MODIFY shlp-fielddescr FROM wa_fielddescr
    INDEX v_tabix TRANSPORTING fieldtext reptext scrtext_s
    scrtext_m scrtext_l.
    ENDCASE.
    ENDLOOP.
    Select the Bill to party customer based on the select options
    FREE: r_ktokd, r_kunnr, r_sortl, r_mcod1, r_ort01, i_knvp.
    LOOP AT shlp-selopt INTO wa_selopt.
    Build a Range for the 5 selection options of the search help
    CASE wa_selopt-shlpfield.
    WHEN 'KTOKD'.
    r_ktokd-sign = wa_selopt-sign.
    r_ktokd-option = wa_selopt-option.
    r_ktokd-low = wa_selopt-low.
    r_ktokd-high = wa_selopt-high.
    APPEND r_ktokd.
    CLEAR r_ktokd.
    WHEN 'KUNNR'.
    r_kunnr-sign = wa_selopt-sign.
    r_kunnr-option = wa_selopt-option.
    r_kunnr-low = wa_selopt-low.
    r_kunnr-high = wa_selopt-high.
    APPEND r_kunnr.
    CLEAR r_kunnr.
    WHEN 'SORTL'.
    r_sortl-sign = wa_selopt-sign.
    r_sortl-option = wa_selopt-option.
    r_sortl-low = wa_selopt-low.
    r_sortl-high = wa_selopt-high.
    APPEND r_sortl.
    CLEAR r_sortl.
    WHEN 'MCOD1'.
    r_mcod1-sign = wa_selopt-sign.
    r_mcod1-option = wa_selopt-option.
    r_mcod1-low = wa_selopt-low.
    r_mcod1-high = wa_selopt-high.
    APPEND r_mcod1.
    CLEAR r_mcod1.
    WHEN 'ORT01'.
    r_ort01-sign = wa_selopt-sign.
    r_ort01-option = wa_selopt-option.
    r_ort01-low = wa_selopt-low.
    r_ort01-high = wa_selopt-high.
    APPEND r_ort01.
    CLEAR r_ort01.
    ENDCASE.
    ENDLOOP.
    Retrieve data from KNVP table for the above selected ranges
    Doing query to retrieve data for the search help
    SELECT knvp~kunnr
    kna1~name1
    kna1~ort01
    kna1~stras
    knvp~kunn2
    INTO TABLE i_knvp
    FROM knvp
    INNER JOIN kna1
    ON knvpkunnr = kna1kunnr
    WHERE
    knvp~parvw = 'RE' AND " Bill to Party
    knvp~kunnr IN r_kunnr AND
    kna1~ktokd IN r_ktokd AND
    kna1~sortl IN r_sortl AND
    kna1~mcod1 IN r_mcod1 AND
    kna1~ort01 IN r_ort01.
    CHECK sy-subrc = 0.
    DELETE ADJACENT DUPLICATES FROM i_knvp.
    Select the short text for kunn2 from kna1.
    Move all the selected records to Record_Tab
    LOOP AT i_knvp INTO wa_knvp.
    v_tabix = sy-tabix.
    SELECT SINGLE name1 FROM kna1
    INTO wa_knvp-name1_2
    WHERE kunnr = wa_knvp-kunnr.
    MOVE wa_knvp TO record_tab-string.
    APPEND record_tab.
    CLEAR record_tab.
    MODIFY i_knvp FROM wa_knvp INDEX v_tabix.
    CLEAR wa_knvp.
    ENDLOOP.
    rc = 0.
    IF rc = 0.
    callcontrol-step = 'DISP'.
    ELSE.
    callcontrol-step = 'EXIT'.
    ENDIF.
    EXIT. "Don't process STEP DISP additionally in this call.
    WHEN 'PRESEL1'.
    WHEN 'DISP'.
    WHEN OTHERS.
    ENDCASE.
    ENDFUNCTION.
    END OF FUNCTION MODULE Z_CUSTOM_SEARCH -
    END OF CODE SAMPLE -
    Save and activate at every step.
    Regards,
    Chandra
    (Award points if helpful)

  • Shipto search help for customer

    Hi Experts,
    Can anybody help on my requirement.
    Requirement:
    I have field KUNNR as my selection screen(select option).
    Whenever user get F4 help of  customer ,Customer number will always
    be ship to. A drop down selection is required to search for the ship to.
    For my requirement I want to create custom search help,need to assign that searchhelp to field KUNNR.
    I want to pick          Kunnr
                                    parvw = 'SH'  from KNVV.
    Can anyone help me on logic? and how to assign it?
    Thanking you...
    Best Regards,
    Rekha.

    Hi
              Use below Code snippet
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR Kunnr-low.
       PERFORM f4helpShipto.
    form f4helpShipto.
    TYPES :  BEGIN OF ty_Kunnr,
                 KUNNR TYPE KNA1-KUNNR,
                 NAME1 TYPE KNA1-NAME1,
                 ORT01 TYPE  KNA1-ORT01,
                END OF ty_KUNNR.
       DATA: it_help TYPE STANDARD TABLE OF ty_KUNNR INITIAL SIZE 0,
           wa_help TYPE ty_KUNNR,
           it_return TYPE STANDARD TABLE OF ddshretval WITH HEADER LINE,
           wa_return LIKE LINE OF it_return.
       SELECT K~KUNNR K~NAME1 K~ORT01 FROM KNA1 AS K
         INNER JOIN KNVP AS P ON P~KUNNR EQ K-KUNN2
    INTO  TABLE it_help
    WHERE K~PARVW EQ 'WE'.
       CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
         EXPORTING
           retfield        = 'KUNNR'
           dynpprog        = sy-repid
           dynpnr          = sy-dynnr
           value_org       = 'S'
           dynprofield     = 'KUNNR'
           window_title    = 'SHIP TO PARTY HELP'
         TABLES
           value_tab       = it_help
           return_tab      = it_return
         EXCEPTIONS
           parameter_error = 1
           no_values_found = 2
           OTHERS          = 3.
    endform.
    Regards:
    Somendra

  • Search help clubbed for 3 fields together

    Hi friends,
    I want to build search help for kunnr, lifnr and hkont in same field.
    Is this possible??
    For eg. if we want, we select customer, or vendor or g/l account.
    Please help if anybody has any idea of the possibility.
    Best regards, Neetu

    Hi
    First you have to ensure that all the values of these fields are in a single field and in a single table
    then for that table you can build a elementary search nhelp
    and can useuse the values for these 3 fields
    in SAP all these fields will not be in single field and in a single table
    you can't build and use the same search help for these fields
    Already I hope there are std search helps for these 3 fields
    see the KNA1,LFA1, and SKA1 tables for these fields
    for customer -DEBI
    Vendor -KRED_C
    GL account - SAKO
    are the std search helps
    Regards
    Anji

  • Customer search

    HI gurus,
    I have customers number like 2, 21, 22 and 23...
    my code:
    DATA: BEGIN OF LT_CUST OCCURS 0,
            KUNNR LIKE KNA1-KUNNR,
            NAME1 LIKE KNA1-NAME1,
          END OF LT_CUST.
    PARAMETERS: I_CUST LIKE KNA1-kunnr.
    REPLACE ALL OCCURRENCES OF '*' IN I_CUST WITH '%'.
    SELECT KUNNR NAME1 FROM KNA1 INTO TABLE LT_CUST WHERE KUNNR LIKE I_CUST.
    LOOP AT LT_CUST.
    WRITE: / LT_CUST-KUNNR, LT_CUST-NAME1.
    ENDLOOP.
    when i pass 2 as parameter then i get 2 in basic list.
    When i pass 2* as parameter, i am not getting any values.
    when i pass *2 as parameter, i am getting 2 in basic list, thats fine.
    how to achieve 2* as search parameter and the result is 2, 21, 22 and 23.
    Giri

    Giri,
    try this...
    give the parameter value in range...
    CUTOMER_RANGE2-SIGN = 'I'.
            CUTOMER_RANGE2-OPTION = 'CP'.
            CUTOMER_RANGE2-LOW = CUSTOMER_NUMBER.
            APPEND CUTOMER_RANGE2.
          SELECT KUNNR NAME1 FROM KNA1
                             INTO CORRESPONDING FIELDS OF TABLE
                             LT_KNA1
                             WHERE KUNNR IN CUTOMER_RANGE1.
    hope this will solve ur problem,
    Regards
    Syed

  • How to use SELECT statement  to extract KNA1-NAME1 and KNB1-ZSABE

    In building table I_KNA1 in  form f_extract_data, an additional select statement is needed to select and  append datafrom (KNA1 and KNB1) to existing I_KNA1
    In form f_extract_data table i_kna1 is populated with data from zd_kna101.(where ZD_KNA101 is a view of KNA1, KNB1 and KNBK.  It's a joint of these three tables.)  This will take care of all customers with KNBK-BANKL and KNBK-BANLN populated.  But this does not include new customers created in SAP CRM (no KNBK records).  Therefore a separate SELECT statement is needed to extract KNA1-NAME1 and KNB1-ZSABE for customers created in SAP CRM(the customers who do do not have BANKL and BANKN). These selected records are then need to be appended to I_KNA1.  It's possible that new selection statement might extract records that are already in existing I_KNA1 table.  IF this is the case, right after the append, sort I_KNA1 and remove duplicate records.
    form f_extract_data.
    select kunnr                         " Customer Number
             name1                         " Name
             zsabe                         " Business Unit
             bankl                         " Legacy Bank Key
             bankn                         " Legacy Bank Account
        from zd_kna101                     " View of KNA1, KNB1, and KNBK
        into table i_kna1
        for all entries in i_doc_by_ref
       where kunnr = i_doc_by_ref-kunnr
        and zsabe in s_zsabe.           
      if sy-subrc <> 0.
        message a116 with 'customer'.  " Customer Table is empty.  HALT!!!
      else.                                                    
        sort i_kna1 by kunnr.                                  
      endif.
    will I have to use the join statement(for KNA1-NAME1 and KNB1-ZSABE using the key as KUNNR) here or give two seperate select statements for extracting data from KNA1 and KNB1 using the key as KUNNR.
    THANKS FOR THE HELP.

    I would suggest using the join on KUNNR.  Maybe something like this.
    data: begin of itab occurs 0,
          kunnr type kna1-kunnr,
          name1 type kna1-name1,
          ZSABE type knb1-ZSABE,
          end of itab.
        select kna1~kunnr kna1~name1 knb1~zsabe
               into table itab
                    from kna1
                       inner join knb1
                            on kna1~kunnr = knb1~kunnr
                                   where ........
    Regards,
    Rich Heilman

Maybe you are looking for

  • How to preform the auto extraction of the Excel file in Import Manager

    Hi Experts, I was performing an automatic import using the Import Manager. In the port, i defined the map name, file type and the automatic execution. But the import manager could not perform the mapping correctly after i putted the Excel file into t

  • All bought titles and albums gone after upgrading I Tunes

    Hi Guys, unfortunately all my recently bought titles and albums from the I Tunes store are gone after upgrading to 10.7.0.21 Can somebody please help me? Thanks you very much... Best regards - Greg

  • Account Payable Check Printing

    We are a hospital who is going live on Oracle E Suite Aug 1, 2011 and we need to make a decision on how to print our accounts payable checks. Here is the options that I have been given on how to print the checks: 1. Check Formats a. Stub on top b. St

  • Zero quantity not allowed

    Hi Experts, One of our clients experiences this error, "zero qty not allowedu201D, even after encoding the item quantity during PO creation. This message always happens when a new item was entered and it will take a few trials before the system accep

  • PRIF-33 and CRS-02307 while changing public network interface, RAC

    Hi, I'm working on an Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production With the Partitioning, Real Application Clusters, Automatic Storage Management. It's a 3 nodes RAC: mgvdb01/02/03 After the installation I had to chang