How to show fixed values instead of field values in ALV cell.

Hi colleagues,
I have a ALV object of type CL_GUI_ALV_GRID.
I have associted a table with it which has a field called refresh type which is of type char1.
My program works fine.
But the problem is,
The refresh_type field has fixed values in its value range.
On display of ALV i want to show the associated fixed value instead of actual value in table content.
I donno the way to do it.
Please help me.
-Trupti

Another way to do this would be to define a conversion exit function for use in the report.
You can copy a SAP-provided function group like ALFA as a template, but you may need untyped importing/exporting parameters. Name the new functions as CONVERSION_EXIT_Zxxx_OUTPUT and CONVERSION_EXIT_Zxxx_INPUT where Zxxx is some string you choose.
In this case the input to the ...OUTPUT function will be the code value from the database and the output value will be the corresponding text. So the code of the function CONVERSION_EXIT_Zxxx_OUTPUT will do the conversion suggested in steps 2 & 3 of Marcin's response above.
Here is an example based on the SFLIGHT model to enhance example report BCALV_GRID_DEMO.
First the conversion function:  (I used 'zalv' as my identifying string for the conversion.)
function conversion_exit_zalv_output.
*"*"Local Interface:
*"  IMPORTING
*"     VALUE(INPUT)
*"  EXPORTING
*"     VALUE(OUTPUT)
  field-symbols:
    <output> type c,
    <carrid> type c.
  assign input  to <carrid> casting.
  assign output to <output> casting.
  select single carrname from  scarr into <output>  " convert code to text
         where  carrid  = <carrid>.
endfunction.
In a copy of program BCALV_GRID_DEMO, make changes in the module pbo.
module pbo output.
  set pf-status 'MAIN100'.
  if g_custom_container is initial.
    create object g_custom_container
      exporting
        container_name = g_container.
    create object grid1
      exporting
        i_parent = g_custom_container.
* " changes start here
    data: gs_fcat type lvc_s_fcat,
          gt_fcat type lvc_t_fcat.
    tables: dd03l.
    select * from dd03l where tabname = 'SFLIGHT'. " fill field catalog
      if dd03l-fieldname = 'CARRID'.
        gs_fcat-inttype = dd03l-inttype.
        gs_fcat-outputlen = 20.
        gs_fcat-coltext = 'Carrier'.
        gs_fcat-seltext = 'Carrier'.
        gs_fcat-edit_mask = '==ZALV'. " == with the string you used to name the functions
      else.
        clear gs_fcat.
        gs_fcat-ref_table = dd03l-tabname.
      endif.
      gs_fcat-fieldname = dd03l-fieldname.
      append gs_fcat to gt_fcat.
    endselect.
* " changes end here
    call method grid1->set_table_for_first_display
      exporting
        i_structure_name = 'SFLIGHT'
      changing
        it_fieldcatalog  = gt_fcat
        it_outtab        = gt_sflight.
  endif.
endmodule.                    "PBO OUTPUT
If you run this amended program, you see appropriate carrier texts in the ALV grid, where the original program had the IATA codes.
This approach makes sense if, for example, the same translation is also required elsewhere, as the function can easily be reused.
best wishes
Ed

Similar Messages

  • I just installed the yahoo messenger. Every time I do that my extensions go missing. How do you fix this instead of having to keep re installing firefox?

    I just installed the yahoo messenger. Every time I do that my extensions go missing. How do you fix this instead of having to keep re installing firefox?

    hello, this sounds like the files in your [[Profiles|profile folder]] that store the information about your extensions might have become corrupted. please go to ''firefox > help > troubleshooting information > profile - show folder...'' then windows explorer should open up your profile folder. in there look for the files named extensions.ini, extensions.sqlite, extensions.sqlite-journal (and in some cases also extensions.txt, extensions.rdf). delete or rename those files and quit firefox, they will be regenerated the next time you launch firefox.
    also see [https://support.mozilla.org/en-US/kb/Unable%20to%20install%20add-ons#w_corrupt-extension-files Corrupt extension files]

  • SharePoint PPS Analytic Chart Drill Down Dimension showing all values instead of corresponding value.

    Hi,
    I have Performance Point Analytic Chart.
    I am doing drill down the bar with one of dimension. System showing all the dimension values instead of correspond values.
    Unwanted dimensions are showing like blank in the chart.
    How to over come this.
    Thanks & Regards
    Poomani Sankaran

    Hi Poomani,
    According to your description, my understanding is that you want the drill down to show only the required dimensions.
    Here is an article about this issue, please check if it is useful:
    http://denglishbi.wordpress.com/2012/03/28/using-perspectives-with-performancepoint-services/
    In addition, as this issue is related to SSAS, I suggest you create a new thread on SQL forum, more experts will assist you with this issue.
    SQL forum:
    http://social.technet.microsoft.com/Forums/sqlserver/en-US/home?category=sqlserver
    I hope this helps.
    Thanks,
    Wendy
    Wendy Li
    TechNet Community Support

  • How to remove target node if source field value is empty SAP PI Mapping

    Hello,
    how to remove target node if source field value is empty in graphical Mapping.
    Like if
    MIddle name in source filed is empty, I would like to eliminate target field from out put XML.
    Thank you
    John

    Hi Jhon,
    If you want to remove all empty tags and you dont to complicate your message mapping, you can use a XSL, after the message mapping,  to remove all the empty tags:
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
        <xsl:template match="node()|@*">
            <xsl:copy>
                <xsl:apply-templates select="node()|@*"/>
            </xsl:copy>
        </xsl:template>
        <xsl:template match="*[not(@*|*|comment()|processing-instruction())
         and normalize-space()='' ]"/>
    </xsl:stylesheet>
    Regards

  • How to Add/Concatenate to a text field, values selected in a combo box

    I have a combo box form field that allows the user to select a value from a list and click on an Add button. The Add button should add/concatenate the vaue selected to a text field in order to create a list of values selected. I'm not sure how to do this using Javascript in Acrobat? I know I need to add the javascript to the Add button's Mouse Up action. Any help would be greatly appreciated. Thanks!

    Thanks so much - it works!
    >>> "Gilad D (try67)" <[email protected]> 9/25/2013 9:16 AM >>>
    Re: How to Add/Concatenate to a text field, values selected in a combo box created by Gilad D (try67) ( http://forums.adobe.com/people/try67 ) in JavaScript - View the full discussion ( http://forums.adobe.com/message/5712118#5712118 )
    Let's say the text field's name is "Text1", and the combo is called "Combo1". You can then use this code as the MouseUp script of the Add button:
    var f1 = this.getField("Text1");
    var f2 = this.getField("Combo1");
    if (f1.value=="") f1.value = f2.value;
    else f1.value = f1.value + ", " + f2.value;
    Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/5712118#5712118
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/5712118#5712118
    To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/5712118#5712118. In the Actions box on the right, click the Stop Email Notifications link.
    Start a new discussion in JavaScript by email ( mailto:[email protected].com ) or at Adobe Community ( http://forums.adobe.com/choose-container!input.jspa?contentType=1&containerType=14&contain er=3286 )
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.

  • Pass javascript field value to  ABAP field value

    Hi all,
          how can i Pass javascript field value to  ABAP field value  and utilise that value within layout.

    since you are new here, may i suggest you to search the forum, before posting a question. This has been discussed many times here.
    to set a js variable value to a ABAP variable value, you cannot do it on the client side, your page has to go for a server rountrip so that the value can be set into a ABAP variable.
    for this we generally follow the approach of setting the js variable value to a hidden html element (input type=hidden) and submit the form, and then in oninputprcessing retrieve the value from the form field and set it to a ABAP variable.
    Regards
    Raja

  • How to update session state from form field values without submitting page?

    Hi,
    I am new to Oracle APEX. I am using Oracle Apex 4.2 on Oracle 11g release 2. The problem is that when I am entering data on a form, when I enter a value in one field and move to the next field, how can I use the value of first field in the validation procedure of next field? I know that when we enter data in fields, the session state is not updated with these values until we submit the page... right... but I have seen that if there is a control of List box type, then Apex gives an option "Action When List changes" where we can choose option to update corresponding session state field with the value of list box item, without submitting the page.
    Now my questions is why this option is only available for List box items? why not for other item types like Text box, Check box,... ? can someone please help me with this?
    (the issue with update of session state depending on page submitting, is that we need a complete network round trip from client to server in order for it. However if we can update session state variables without submitting page, then we can avoid this network traffic).
    Any help will be greatly appreciated. Thanks in advance.

    Create a dynamic action on change and run a PL/SQL process there with the following code:
    BEGIN
       NULL;
    END;Page items to submit > your item.
    This will set the session state without submitting the form.
    Further examples here:
    http://apex.oracle.com/pls/apex/f?p=31517:229
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.apress.com/9781430235125
    http://apex.oracle.com/pls/apex/f?p=31517:1
    http://www.amazon.de/Oracle-APEX-XE-Praxis/dp/3826655494
    -------------------------------------------------------------------

  • Keynote data labels, can I show category names instead of data values?

    I'd like to recreate the chart below in Keynote. The chart below is an excel line chart with the lines removed. In excel I can opt to show category names instead of values for the data labels. Can I do this in Keynote?

    You can select member name or alias or both in the Dimension property while creating the form.
    It is in the same window as explained earlier, you need to just select both the Member and its Aliase to be displayed on the form.
    Thanks,
    Ravi

  • RRI?  How to call ITS URL and pass field value from Bex Query.

    I am doing RRI from query to webaddress,
    i have defined jump(report type: webaddress and reicver report as url) from shopping cart bex query(SRM ) to webaddres.
    here url is SRM ITS base link for monitoring shoppingcart(http://(hostname):(SRM port)/sap/bc/gui/sap/its/bbp_mon_sc?sap-client=200&sap-language=EN).
    jump is working from portal(from bex query ivew).
    but i want to pass value(shopping cart value) to above url and want to skip first screen.
    i have maintained assignment detail by assigning field name against shopping cart infoobject with type url parameter, but its not directly call reciver url with given input field.
    i tried the diffrent combination of url and field assignment as like below:
    1: web address url:http://(hostname):(SRM port)/sap/bc/gui/sap/its/bbp_mon_sc?sap-client=200&sap-language=EN
    assigned field: GS_HEADER-OBJECT_ID
    but when we call reciver url from portal bex ivew, only initial screen come with page url as below:
    http://(hostname):(SRM port)/sap/bc/gui/sap/its/bbp_mon_sc?sap-client=200&sap-language=EN?GS_HEADER-OBJECT_ID='selected number value'
    2: web address url:http://(hostname):(SRM port)/sap(cz1TSUQlM2FBTk9OJTNhc3JtZGV2X0lTRF8wMCUzYUdxdFNqdWdMS2xyTEFEelFTNFlWTnJXRjEzdy05UnhTWXl4TW03c3AtQVRU)/bc/gui/sap/its/bbp_mon_sc/~flNUQVRFPTgzMTcuMDAyLjAxLjAx====#jump_to_selected_sc
    assigned field: flNUQVRFPTgzMTcuMDAyLjAxLjAx
    but when we call reciver url from portal bex ivew, only initial screen come with page url as below:
    http://(hostname):(SRM port)/sap(cz1TSUQlM2FBTk9OJTNhc3JtZGV2X0lTRF8wMCUzYUdxdFNqdWdMS2xyTEFEelFTNFlWTnJXRjEzdy05UnhTWXl4TW03c3AtQVRU)/bc/gui/sap/its/bbp_mon_sc/~flNUQVRFPTgzMTcuMDAyLjAxLjAx====#jump_to_selected_sc?flNUQVRFPTgzMTcuMDAyLjAxLjAx='selected number value'
    I have seen the source code of that url(inital screen and after entring the value to that screen) too.
    how to call webadress(SRM ITS base shopping cart URL) with passing the one of field value of that url screen?
    Thanks and regards,
    Dushyant.

    Declare the gv_orderid in modulepool program.
    And Declare the parameter as import parameter in smartform.
    CALL FUNCTION  lv_form
       EXPORTING
    *   ARCHIVE_INDEX              =
    *   ARCHIVE_INDEX_TAB          =
    *   ARCHIVE_PARAMETERS         =
    *   CONTROL_PARAMETERS         =
    *   MAIL_APPL_OBJ              =
    *   MAIL_RECIPIENT             =
    *   MAIL_SENDER                =
    *   OUTPUT_OPTIONS             =
    *   USER_SETTINGS              = 'X'
         i_input                    =  gv_orderid
    * IMPORTING
    *   DOCUMENT_OUTPUT_INFO       =
    *   JOB_OUTPUT_INFO            =
    *   JOB_OUTPUT_OPTIONS         =
    * EXCEPTIONS
    *   FORMATTING_ERROR           = 1
    *   INTERNAL_ERROR             = 2
    *   SEND_ERROR                 = 3
    *   USER_CANCELED              = 4
    *   OTHERS                     = 5

  • Data Object Fields on MI Client 7.1: Null value instead of empty value

    Hi,
    We are migrating an application from Mobile 7.0 to 7.1 and we don´t know if our Data Objects are missing some configuration, but when a field is sent to MI Client with empty (blank) value, we get this field in the application with a null value instead of an empty value.
    This same application works fine in Mobile 7.0 and when a field with empty value is sent to MI Client, a empty value is get by the application.
    Has anyone any idea?
    Thanks.

    Hi,
    SAP has solved the issue. They told us to add the following parameter in defaults.properties:
    com.sap.tc.mobile.bc.string.trim=false
    Thanks.

  • Show Field Values if other Field Value Different

    Hey,
    I am using TOAD for Oracle 10.5. There is a select statement that is not populating requested results.
    Data:
    JOB                    SAL
    PRESIDENT             5000
    MANAGER               2850
    MANAGER               2450
    MANAGER               2975
    ANALYST               3000
    ANALYST               3000
    CLERK                 800
    CLERK                 1100
    CLERK                 950
    CLERK                 1300
    SALESMAN             1600
    SALESMAN             1250
    SALESMAN             1250
    SALESMAN             1500Select Statement
    SELECT JOB, SAL
       FROM  EMP
       WHERE JOB IN (
                   SELECT JOB
                    FROM EMP
                    GROUP BY JOB
                    HAVING COUNT(*) > 1)
                    ORDER BY JOB;Once select statement executed only JOB = PRESIDENT record is removed, not results needed.
    JOB                    SAL
    MANAGER               2850
    MANAGER               2450
    MANAGER               2975
    ANALYST               3000
    ANALYST               3000
    CLERK                 800
    CLERK                 1100
    CLERK                 950
    CLERK                 1300
    SALESMAN             1600
    SALESMAN             1250
    SALESMAN             1250
    SALESMAN             1500Correct Data, JOB values PRESIDENT and ANALYST records should not appear.
    PRESIDENT does not appear but the ANALYST value shows because the statement
    is producing duplicate JOB values. I would like to show records only if the JOB values have
    different SAL values, not duplicate JOB values. Only if the SAL value is different based on JOB.
    JOB                    SAL
    MANAGER               2850
    MANAGER               2450
    MANAGER               2975
    CLERK                 800
    CLERK                 1100
    CLERK                 950
    CLERK                 1300
    SALESMAN             1600
    SALESMAN             1250
    SALESMAN             1250
    SALESMAN             1500I hope someone can help me out on this one.

    Hi,
    COUNT (*) tells how many rows are in a group. It has nothing to do with any values in any columns.
    I think you want COUNT (DISTINCT sal) in this case. It will tell you how many different values of sal are in the group.
    SELECT JOB, SAL
       FROM  EMP
       WHERE JOB IN (
                    SELECT JOB
                    FROM EMP
                    GROUP BY JOB
                    HAVING COUNT (DISTINCT sal) > 1          -- Changed
       ORDER BY JOB;Edited by: Frank Kulash on Dec 9, 2010 10:34 AM
    Added example.

  • How to find roles with certain org field values?

    agr_1252 holds its values in Low and High fields.   So if I want to discover roles giving visibility to certain $RSINFOAREA such as LRDR* and MRT, how to do it?   Most roles in our system use ranges in the org.fields, such as 0DA - ZL*, so I would need to identify these and change the ranges to prevent visibility to our sensitive infoareas.   But I don't see a way to do this with SQVI and there are no canned reports in SUIM.   Has anyone faced and solved this b4?

    Hi
    It seems to me at least on my system that RSINFOAREA is not an org element field - and in your landscape it has been changed into an org field. You can receive values of RSINFOAREA field either from agr_1251 or agr_1252 - depending upon the status of the field. Now after you have obtained value in ranges - you can see the exact individual values contained in ranges through table RSDAREA (Directory of InfoAreas) - hope this will help you.
    Best Regards
    Prashant

  • How can we hide the non key field values in the sm30 display

    hello experts,
    I have to protect the non key field values in the sm30 display , can u help me out wat changes i have to do in the layout.

    Hello Gopal,
    What do you mean by 'protecting' your non-key field value?
    1) You want to display it, but make it non-changeable
    A - Make the field as output-only in screen, as already answered by a preivous collegue
    2) You do not want to display this field at all
    A - Goto the DDIC definition of the view (not possible for a table directly), and maintain the required field as a Hidden. After activating, remember to re-generate the maintenance dialogue. Also, please maintain Event 21, in case you want to access/change the value of this field in background.
    3) You want to maintain special validations/checks for the field
    This can be easily done by introducing your modules within the CHAIN-FIELD commands in the PAI of the generated screens.
    Best Regards,
    Rekha

  • How to receive a valid value instead of " null " value

    Hi people,
    I'm making this SELECT statement:
    SELECT I.id_cd, I.cantor_cd, I.titulo_cd, I.videoclip_cd, SUM(T.vezes_cd) as
    VEZES, MAX(T.dt_cd) as DATA from t_indicetmp I LEFT JOIN t_tocado T ON
    I.id_cd=T.id_cd
    GROUP BY I.id_cd, I.cantor_cd, I.titulo_cd, I.videoclip_cd ORDER BY
    SUM(T.vezes_cd) DESC
    So, I got this result
    id_cd.........cantor_cd.........titulo_cd.........videoclip_cd.........vezes.........data
    3...............cantor1.............titulo1............S........................9................09/03
    1...............cantor2.............titulo2............N........................8................09/03
    2...............cantor5.............titulo5............n........................<null>.........<null>
    The question is, is there a way to receive for example "0" instead of "<null>" value?
    It's happening because there's no registry for the id_cd=2 in the "t_tocado" table.
    thank's very much,

    The question is, is there a way to receive for example "0" instead of "<null>" value?1) NVL function
    http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96540/functions88a.htm#91645
    2) DECODE function
    http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96540/functions33a.htm#1017439
    3) CASE statement
    http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96540/expressions5a.htm#1033394
    Rgds.

  • How to show message on selection screen  status bar if alv is empty.

    Hi,
            Can anyone tell me how to show message on selection screen status bar when our final internal table or alv is empty .
           i am getting message on alv status bar, where no data is in alv but i want to stop it to selection screen and show message there only.
    Regards,
    Ranu

    Hi,
    After populating the final internal table do this check,
    if it_final [] is initial.
    message 'No data available' TYPE 'S' DISPLAY LIKE 'E'.
    exit.
    endif.
    This will be displayed in the selection screen itself
    Regards,
    Vikranth

Maybe you are looking for

  • Dynamic Logo file names in PO XSL-FO stylesheet

    We have different company logo files for different operating units. Hence , we require to use a dynamic logo file name in XSL-FO template. When I use the below for a single file it works.      <fo:inline> <fo:external-graphic content-width="50pt" con

  • Premiere CS5 import avi clips without sound. How can I import avi clips with sound without convert?

    Dear Adobe Forum, I have the following problem, please help: I would like to import avi clips in adobe premiere. All clips have the same avi codec. But unfortunately my adobe premiere does not import the sound of a few avi clips. It is wired because

  • Set button URL

    What is step by step for attaching URL to a button in Flash 8? Documentation is atrocious; there is no explanation. Also, I had to copy image to blank keyframe on a separate layer for each button state to get button to work properly. Creating button

  • SDK is missing GPL component lib\aot/bin/as/i686-apple-darwin9-as.exe

    Hi, Just downloaded AIR 3.3 release SDK, tried to package and I get this problem - the file 'i686-apple-darwin9-as.exe' is missing by the looks of it. The command I use is this adt.bat -package -target ipa-debug-interpreter-simulator -connect 192.168

  • RAC service can't start after upgrading to 10.2.0.4

    Hi All, After upgrading to 10.2.0.4 from 10.2.01 (linux32 with 2 nodes), I am experiencing the following: 1. The rac service (created after the database was created, not the default service) can not start after the database started with "prkp-1030" e