Selection screen -Query

Hi Gurus:
I have a query which has selections form extars tab in the
infoset and one selection for language from the selection tab.
The problem is that when this selection in teh selection screen
from the selection tab is filled with no language(blank)
and run withoutselecting anyother selection it gives all teh result,
similaryly if I put in a language and in it and run it still shows up
witha ll the result. Actually I would like to see only thiose
materials with description for which the language is entered and not all .
Since this selection copmes from teh selection tab fo the infoset
its not filtering as required but the other selection criteria which
comes from teh extra tab does filter accordingly.
Could anyone sufggest as how tyo gho about doing it so
that it shows the result by filtering from this languiage criteria also.
My selection screen is as follows.
(General data selection)
TDG Language                    ___<----- this comes from the selection tab in infoset
(Report-specific selection)
Material Number                 ____               to    ____ (these comes from the extra tab in infoset)
Material Type                   ____               to    ____
Material Desc. Language         ____               to    ____
Layout      ____
Thanks

I have two different columsn(additional field) for two diffrenet texts.
FOr the first one its :and its sequence is 2.
data: name3 type tdobname,
      language3 type spras,
      tlines3 type table of tline with header line.
language3 = sy-langu.
clear tdgtextz1.
name3 = mara-matnr.
call function 'READ_TEXT'
  exporting
    id                            = 'PRUE'
    language                      = language3
    name                          = name3
    object                        = 'MATERIAL'
  tables
    lines                         = tlines3
  exceptions
    others                        = 1.
if sy-subrc = 0.
  loop at tlines3.
    if sy-tabix = 1.
      tdgtextz1 = tlines3-tdline.
    else.
      concatenate tdgtextz1 tlines3-tdline into
          tdgtextz1 separated by space.
    endif.
  endloop.
endif.
if p_spras = language3.
check not tdgtextz1 = ' '.
tdg_text = ' '.
endif.
for the second one as follows and has the same sequence in infoset as 2.
data: name2 type TDOBNAME,
      language2 type SPRAS,
      tlines2 type table of TLINE WITH HEADER LINE.
language2 = sy-langu.
clear tdg_text.
name2 = mara-matnr.
CALL FUNCTION 'READ_TEXT'
  EXPORTING
    ID                            = 'PRUE'
    LANGUAGE                      = language2
    NAME                          = name2
    OBJECT                        = 'MATERIAL'
  TABLES
    LINES                         = tlines2
  exceptions
    others                        = 1.
IF SY-SUBRC = 0.
  loop at tlines2.
    if sy-tabix = 1.
      tdg_text = tlines2-tdline.
    else.
      concatenate tdg_text tlines2-tdline into
          tdg_text SEPARATED BY space.
    endif.
  endloop.
ENDIF.
if p_spras = language2.
check not tdg_text = ' ' .
tdgtextz1 = ' '.
endif.

Similar Messages

  • Wrong date format when using selection screen query

    Hi all,
    I have a problem in a report when usign the selection screen of the query.
    the system has been upgraded recently from a 3.5 to 7.0. when a query is run in the bex web the user can put in the selection date needer to run the query.
    currently if u select a month using the selection screen next to the input form, the month will show up in the input field
    as 006 09 (006space09) instead of 06.2009 for the selection of june. 
    does anyone know how to fix this? it was working good using the 3.5 version of the bex web.
    Any help apriciated

    Using the list cube transaction and using the selection sceen and selecting the month it does put the right selection in the input field. ive also just tested it using de bx excel plugin and using the selection screen the correct value is set in the input field.  so i think it more of a bex we b problem but i dont know where to start the search for the solution.

  • How to arrange the variables in Selection Screen (Query)

    Hi,
    I am having Query-A (Contains 4 variables, among those, one is mandatory and one is Replacement Variable)
    Using Replacement Variable am calling Query-B (Contain one mandatory Variable).
    Now when am executing Query-A, in Variable screen its shows
    Query-A--Mandatory Variable
    Query-A--*********
    Query-A--*********
    Query-B--Mandatory Variable. (like this)
    But i need the Query-B--Mandatory Variable to be position in top. how to achieve this.
    Regards,
    Jackie.

    Hi Friends,
    Thanks for your quick replies, but like Dieu said i need to rearrange Variable between Query-A and Query-B.
    Query-A Variables                                
    Query-A--Mandatory Variable               
    Query-A--********
    Query-A--********
    Query-B Variables
    Query-B--Mandatory Variable
    I have join both the Query using Replacement Path Variable.
    Now when i execute Query-A, it shows the variables in Query-B also. Like this
    Query-A--Mandatory Variable          
    Query-A--********
    Query-A--********
    Query-B--Mandatory Variable
    But i need to like the following
    Query-A--Mandatory Variable          
    Query-B--Mandatory Variable
    Query-A--********
    Query-A--********
    Regards,
    Jackie
    Edited by: Jackie on Aug 11, 2008 12:04 PM
    Edited by: Jackie on Aug 11, 2008 12:05 PM

  • Wrong sequence in selection screen generated by ABAP Query

    Hi,
    I am developing a query to display the data in the view.
    My query has 8 selection fields totally.
    As part of my requirement I have added selection parameter in the
    selections tab of the infoset and maintained the sequence as 9.
    Inspite of maintaining the sequence number as 9 in the infoset, It is
    appearing first in the selection screen of the query.
    I tried putting different numbers in the sequence number, but even it
    is appearing first in the selection screen.
    Can you please let me know how to display the selections declared in
    the infoset as per the sequence required.
    Thanks,
    Madhuri.

    Actually what happen when you declare your own fields in ABAP query . you have to care about the sequence . As an example if you’re selecting lets say state name , you have two variables
    <b>1-state
    2- land</b>
    for state you have to select land first , if your state is first and land is 2nd it gave you the error of sequence .
    Because you have to get data in land first in order to get state specific to the land .
    it should be
    1-Land
    2-State
    Just see the your fields , I’m sure you’re missing that .
    <b>You can also see the NO ( field ) in Query ( Sq03 ) . where you can define the seqence on selection.</b>
    hope this’ll help you .
    Pl...Award the points .
    Thanks
    Saquib<b></b>
    Message was edited by: Saquib Khan

  • Selection screen field not working in Query

    Hi Gurus!
    I have a small problem with one of my query that I just created for finding status of our customers. I have a code section which handles it all . The problem is that I ahve a user field called "Check date" which I ahve used in selection screen as well as the layout, when I put a value in this field in the selection screen the report dosent give any output " NO data to display" but when I leave it open it does give me the out put with the saem check date as I ahd entered earlier in my selection screen.
    I am not sure where my selection code is working wrong . Could anyone please help me out please.
    DATA: ls_vakpa LIKE vakpa.
    DATA old_date LIKE sy-datum.
    old_date = key_date - num_days.
    status = 'ACTIVE'.
    check_date = old_date.
    * (If I entere this field (check_date) with any date
    *  and run it does not give me output and without
    * entry it dioes give output.
      SELECT SINGLE * FROM vakpa INTO ls_vakpa
          WHERE kunde = kna1-kunnr
       AND audat > old_date.
          IF sy-subrc <> 0.
        SELECT SINGLE * FROM vakpa INTO ls_vakpa
            WHERE kunde = kna1-kunnr
          AND audat < old_date.
          IF sy-subrc = 0.
          ls_audat = ls_vakpa-audat.
          ls_vbeln = ls_vakpa-vbeln.
        ELSE.
          CLEAR ls_audat.
          clear ls_vbeln.
        ENDIF.
        status = 'INACTIVE'.
      ELSE.
        ls_audat = ls_vakpa-audat.
        ls_vbeln = ls_vakpa-vbeln.
      ENDIF.
    Edited by: Rob Burbank on Apr 7, 2010 12:08 PM

    DATA: ls_vakpa LIKE vakpa.
    DATA old_date LIKE sy-datum.
    old_date = key_date - num_days.
    status = 'ACTIVE'.
    check_date = old_date.
    if old_date is initial.
       old_date = key_date - num_days.
       check_date = old_date.
    endif.
      SELECT SINGLE * FROM vakpa INTO ls_vakpa
          WHERE kunde = kna1-kunnr
    *      AND audat > old_date.
        AND audat > check_date.
      IF sy-subrc <> 0.
        SELECT SINGLE * FROM vakpa INTO ls_vakpa
            WHERE kunde = kna1-kunnr
    *        AND audat < old_date.
          AND audat < check_date.
        IF sy-subrc = 0.
          ls_audat = ls_vakpa-audat.
          ls_vbeln = ls_vakpa-vbeln.
        ELSE.
          CLEAR ls_audat.
          clear ls_vbeln.
        ENDIF.
        status = 'INACTIVE'.
      ELSE.
        ls_audat = ls_vakpa-audat.
        ls_vbeln = ls_vakpa-vbeln.
      ENDIF.

  • Analysis Authorization : Selection screen not appearing for query

    Hi,
    I am facing an issue with analysis authorization. I have created the new roles and assigned to the users. For one user when I am executing the query, the selection screen is not coming up and it shows error message to specify the variables. Whereas its running for all other users.
    In S_RS_COMP I have selected Type of a reporting component as Query View, Query & Template structure. I also tried adding Variable in this field but that also did not help.
    Please let me know if you have faced similar issue.
    Regards,
    Manish

    Hi,
    Go to your query desinger opend your query and select your variable in that you have see first "Ready Input Query" Check box is selected or not. It's not selected you can select that check box.
    Your problem will be sloved.
    Thanks & Regards,
    venkat.

  • How to add customize message on the variable selection screen in the query

    Hi all,
    Can we add an customise message on the variable selection screen in the query? If yes please let me know how it can be achevied?
    Thanks,
    Rani

    Hi Rani,
    I faced a similar issue (for what I understand your request is).
    My requirement for the Variable Screen was to do:
       1) place a link to a ppt file
       2) remove buttons "Save", "Save As...), "Delete"... the standard buttons come when running the Query or WebTempl
    We were using a Web Templ for BI7.0
    I struggled trying to find out how to do it. My conclusions are:
    - WAD, not sure we can accomplish it using a Web Template but i did not "play" a lot with the Web_Template Properties in order to know
    - XHTML, I was told in my post HTML modification was the way, but I have close to nil background in HTML and couold not find the way of accessing the Variable Entry screen
    For instance, I had to remove similar buttons and change some font size from a link on the Web Template (WAD), which was pretty straight forward. In WAD the buttons come with its own icon and to increase the Font size for that link we used XHTML (<font size="2" >). But the heck of the variable screen...well, i just did not get trhough to it to modify it in any way.
    Good luck,
    Definetly in a Query I would say that no.
    alex
    PS: If anyone had a better insight, please feel free to share it.

  • Infoset Query- How do I clear the in-built selection screen in LDB

    Dear Experts,
    When LDB is used in queries unwanted selection screen blocks appear.
    Please help in getting rid of the same.
    Kind Regards
    Jogeswara Rao

    Hello Jogeswara,
    1.  In the Infoset push button Extras and then select Code tab.
    2.  Select AT SELECTION-SCREEN OUTPUT for Code Section.
    Suppose your query is based on logical database KDF and you went to hide the SELECT-OPTIONS for Company Code.
    loop at screen.
      if SCREEN-NAME = '%_KD_BUKRS_%_APP_%-TEXT' OR
         SCREEN-NAME = '%_KD_BUKRS_%_APP_%-OPTI_PUSH' OR
         SCREEN-NAME = '%_KD_BUKRS_%_APP_%-TO_TEXT' OR
         SCREEN-NAME = '%_KD_BUKRS_%_APP_%-VALU_PUSH' OR
         SCREEN-NAME = 'KD_BUKRS-LOW' OR
         SCREEN-NAME = 'KD_BUKRS-HIGH'.
        screen-invisible = '1'.
        screen-active = '0'.
        modify screen.
      endif.
    endloop.
    Kind Regards,
    Rae Ellen Woytowiez

  • Sorting Currency conversion Variables in Query Selection screen

    Hi Experts,
    I have an issue in sorting variables.
    A Currency translation is used here which has two selection options here, one for "Currency" and one for "Currency conversion date". They just pop in somewhere in the selection screen with out order. I want to put them together either in the middle or at the bottom.
    They are not visible in the Variable sequence tab of query properties.
    I changed the text for each of them (Ex. "XCurrency"), so that it sorts alphabetically, but no difference.
    Had anybody come accross this issue before.
    regards
    G Rai

    Hi,
    This seems strange that the variable does not show in the query properties. One thing I can suggest it to try changing the technical name/desciption of the variable if that changes the order.
    Please update back the thread if that helps.

  • Selection screen modification in case of SAP Query

    Hi All,
    I want to modify the selection screen in a standard progam.
    This program is getting generated through SAP QUERY.
    i want to modify some fields and also delete some fields in the
    selection screen. All these fields which i want to modify or delete
    are the logical database fields.So i can't do it through the t-code SQ01
    and SQ02. Also this is a program generated through the SAP QUERY,
    so i can't modify the generated code. Request if any one of you can suggest me to solve this.
    Waiting for a prompt reply!!
    Thanks,
    Rupesh

    Go to SQ02
    Select your Infoset-->Change
    On next Screen.
    Select GoTo->Code->Initialization.
    Write there code
    LOOP AT SCREEN.
      IF screen-name EQ 'SP$00004'.
           screen-required = 1.
           MODIFY SCREEN.
      ENDIF.
    ENDLOOP.

  • Selection screen validation in HR ad hoc query

    Hi Experts,
    I have created a query in SQ01. My infoset is created using Logical database PNPCE. Selection criteria contains Fields  Personnel Number and Employment status. so when the query will be run, I want to display error message if invalid personnel number or Employment status is entered. Please let me know, How do I achieve it.
    Thanks in advane.
    Regards.

    Hi
    After declaring selection screen fields.
    select the field to handle validation and click on the button 'Check coding for
    Element' .
    you will get a block to handle the validation.

  • Addition of checkbox and 2 fields in ABap query selection screen

    Hi
    I need to add chack boxes and 2 fields in ABAP query which is using LDB QMI. can u pls let me know how to do that.

    Hi Tarun,
    I am still not clear with the problem..I guess you require plant in your selection screen which you have.
    i guess if you go to sq01tcode there is a option infoset query from where you can give your selection options and value.
    have you selected all the fields in infoset and made a selection screen?
    When you have done with your infoset you just need to diplay the fields and there is a automatic program generated.
    Let me know...
    Regards,
    Nihkil.

  • SQ01 -  Include a check box on ABAP query Selection screen

    Hi Experts,
    For my Abap Query, on the selection screen i am planning to include a check box such that if i click on the check box then a field will be displayed in the resulting output . On the other hand if i do not check on i should not be able the field in the output.
    Please tell me how do i do this.
    Thanks
    Venkata Pradeep.

    In infoset, Extras code tab
    Code section: At selection-screen output
    Do something like below:
      IF radiobutton1 = 'X'.    
         LOOP AT SCREEN.      
              IF screen-group1 = 'XXXX'.         "XXX is the filed group name you want to hide., you have to                                                                  find out what is it.
                   screen-input = '1'.        
                   screen-invisible = '0'.        
                   MODIFY SCREEN.      
              ENDIF.    
         ENDLOOP.  
    ELSE.   
         LOOP AT SCREEN.     
              IF screen-group1 = 'XXX'.        
                   screen-input = '0'.       
                   screen-invisible = '1'.       
                   MODIFY SCREEN.     
              ENDIF.   
         ENDLOOP. 
    ENDIF.

  • Validate plants selected in Abap Query selection screen

    Hi Everyone,
    I have a requirement wherein i have to validate 'authority check' for the plants populated in the selection screen in an already created abap query.
    I tried adding code in the code section. But i dont know how to use the select-option parameter. It already exists(VBAP-WERKS) in the table which is used for join, so i cannot add it in the additional fields. Am i correct ?
    Also, i saw that the report program for this query uses this parameter sa SP$00008. I tried using it but it gives an error The IN operator with "SP$00008" is followed neither by an internal table nor by a value list.
    Please help.
    Also, please advice whether this requirement can be catered in this query alone? or should i go with writing a new report program for this? ( i personally feel that this would beat the purpose of using Abap Query. )
    Regards,
    Tarun

    Hi Tarun,
    I am still not clear with the problem..I guess you require plant in your selection screen which you have.
    i guess if you go to sq01tcode there is a option infoset query from where you can give your selection options and value.
    have you selected all the fields in infoset and made a selection screen?
    When you have done with your infoset you just need to diplay the fields and there is a automatic program generated.
    Let me know...
    Regards,
    Nihkil.

  • Checkbox in the ABAP query selection screen

    Hi experts,
    The reqiurement is to add checkbox(parameter name: EX_ZE_ST) to the selection screen of the query and if its checked then the records with the quantity = 0, should not be displayed in the output.
    I added a check box and now my issue is, how to suppress displaying the record having quantity = 0.
    that quantity field is a custom added field and in sq02 i selected that quantity( Z_HANDQTY) field and gone into the code for the same and wrote below code...
    the total generated table view for this query is : marav
    if EX_ZE_ST = 'X' and Z_HANDQTY = 0.
    break-point.
    clear: marav, Z_MATDESC, Z_MATGRPDESC, Z_TAXIND,
            Z_TAXTYPE, MARD, MARD-LGPBE, Z_PREVMATNR,
            Z_CSTTOTAL, Z_CSTUNIT, Z_VSTOCK.
            FREE MEMORY ID 'AQLISTDATA'.
    endif.
    But still i could see a blank line in the output if that record has quantity( Z_HANDQTY) = 0.
    Thanks in advance...
    Karthik

    hi,
    Try this wa y...
    if EX_ZE_ST = 'X' and Z_HANDQTY = 0.
    break-point.
    clear: marav, Z_MATDESC, Z_MATGRPDESC, Z_TAXIND,
    Z_TAXTYPE, MARD, MARD-LGPBE, Z_PREVMATNR,
    Z_CSTTOTAL, Z_CSTUNIT, Z_VSTOCK.
    FREE MEMORY ID 'AQLISTDATA'.
    Continue.
    endif.

Maybe you are looking for

  • Has anyone used Mountain Lion with Time Machine for the WD MyBook Live Duo

    This NAS is working with OSX Lion.  But since I had trouble moving up to Lion with my previous WD NAS drive, I want to make sure that it works. Thanks

  • Can't reconnect files from my external HD

    I just installed my new external HD (OS Extended Journal) and moved the files in my project there. I deleted the old files on the internal HD. When I open my project all files are offline (of course) so I reconnect them in the browser. The files are

  • I can't write app reviews in the AppStore

    Lately, I cannot write app reviews. I can tap a star rating but when I go to tap the "write a review", the screen huts flashes then reloads the same screen without an entry box. This has happened with several apps.

  • Cost Value in COPA

    Dear All, In our organisation we have two units, whereas 1 units will be using the standard cost estimate and the other will not use the standard cost estimate.  The standard price of the product will be updated in the material master manually for in

  • Access files included in swc? (not classes)

    Hi! I saw it was possible to include files in a swc (for example, images, videos, etc) but I didn't find how access them from an other project. For example I have this folder tree : src   - assets     - images         test.jpg     - videos         te