How to remove leading zeros for an item number within quickviewer

how to remove leading zeros for an item number within quickviewer. Pls help

ask your abap guy to do  it. not portal guys business.

Similar Messages

  • How to remove leading zero from Material Number

    Hello Everyone,
    I need to figure it out how to remove leading zero from material number. Cureently extractor is sending material number as 100663. But when comes into BI i am getting as "000000000000100663" and similariy in report it is appearing as "000000000000100663". Now my client wants me to exclude preceeding zero for a material in all the reports.
    Is there any setting in query desinger to handle this issure or in the backend.
    Need your inputs.
    Thanks,
    Lasya.

    Hi
    you can use the function Module
    CONVERSION_EXIT_ALPHA_OUTPUT in the start routine
    to test this go to SE37  --- give the CONVERSION_EXIT_ALPHA_OUTPUT -
    >display -
    > F8
    in the input give 000000456
    and execute
    the out put will be 456
    for getting Zeros you can use
    CONVERSION_EXIT_ALPHA_INPUT--- to remove leading zeros
    Santosh
    Edited by: Santhosh Nagaraj on Oct 29, 2009 10:52 PM
    Edited by: Santhosh Nagaraj on Oct 29, 2009 10:54 PM

  • How to remove leading zeros from variable

    hi,
       how to remove leading zeros from variable like it_vbap-matnr.
    value in it_vbap-matnr is 000000000000000358
    i want to remove leading zeros so that it become 358
    regards
    deepak

    You can use Function Module <b>'CONVERSION_EXIT_MATN1_OUTPUT'</b>
    This Function Module will eliminate leading Zeros.
    For each MATNR Value read form DB Table,u can eliminate Leading zeros and then modify ur Internal table.
    I think u will not get leading Zeros into utr Internal table when u read from VBAP.
    Bcoz MATNR in VBAP itself have Conversion routine.
    If u r getting leading zeros,U can use following Logic.
    tables:
      vbap.
    data:
       t_vbap like standard table of vbap.
    select matnr
    from vbap
    into corresponding fields of table t_vbap.
    loop at t_vbap into vbap.
      CALL FUNCTION 'CONVERSION_EXIT_MATN1_OUTPUT'
          EXPORTING
            INPUT         =  vbap-matnr
          IMPORTING
            OUTPUT        =  vbap-matnr
      modify t_vbap from vbap transporting matnr.
    endloop.
    Hope this will work.....

  • Remove Leading zeros for Material in Transformation

    Hi Experts,
    I'm using DTP first time. I don't have much exp on DTP & Transformations.
    I'm creating infocube with some objects. I want to remove leading zeros for zmaterial.
    In 3.x writen update routines as fallows:
    data: zmat(18) type c.
    zmat = COMM_STRUCTURE-/BIC/ZMAT.
    shift zmat left deleting leading '0'.
    result value of the routine
      RESULT = zmat.
    I'm confusing in Transfermation where to write this routines.
    I'm writing in Transformation as fallows:
    data: zmat(18) type c.
    zmat = SOURCE_FIELDS-/BIC/ZMAT.
    shift zmat left deleting leading '0'.
    RESULT = zmat.
    But it's getting remove zero's.
    Anybody suggest on this.
    Siri

    Dear Sir,
    No confusion at all.
    Just double click on the Target Infoobjct i,e Material object in Transformation, you will see a wizard popping up.
    There you will see a option called "RULE TYPE" and the default value will be "Direct Assignment". In the same check box click on the drop down icon and select "Routine".
    The moment you select the routine option, it will open up ABAP workspace where in you can write your routine and get the desired result.
    Hope it helps.

  • Removing leading zeros for the quantity field

    Hi all,
    In my script form there is a quantity field, of 13 and 3 decimals , on the out put its taking that much space un neccesarily,and messing up.
    how to make this adjustable in the provided space.
    It always 3 digits and 2 decimal points in our case.
    Please help me out,
    Thanks,
    Praveen

    Hi,
    For removing leading zeros
    &V_VARIABLE(Z)&
    Thanks,
    Naren

  • How to remove leading zeroes of string

    Hello All,
    I have a scenario where Partnumber string type shows 00000000012345 format, I want to remove leading zeroe and displ only 12345 .
    How to do it,
    Suggest

    Hi Pradeep,
      Please go through this wiki. [https://www.sdn.sap.com/irj/scn/wiki?path=/display/java/remove%252bleading%252band%252btrailing%252bzeros%252bfrom%252ba%252bstring]
    It explains how to remove zeros from strings.
    extract from the wiki. This is an efficient way.
    public java.lang.String removeLeadingZeros( java.lang.String str ){
         if (str == null){
               return null;
          char[] chars = str.toCharArray();
          int index = 0;
          for (; index < str.length();index++){
               if (chars[index] != '0'){
                    break;
         return (index == 0) ? str :str.substring(index);
    If you want to show this string in a table instead of the ones with zeros you can create a calculated attribute  of type string on the same node and in the getter method read the string with zeros using getAttributeValue() api and pass the string to the above method and return that string value.
    You can also have another approach if you will only have numbers in your string. Have a calculated attribute of type int. In the getter method read the String using getAttributeValue() api and then convert it to an int using Integer.parseInt(String) and return the int value.
    Regards,
    Sanyev

  • How to remove Leading zeros from MATNR "at Database Level"

    Hi,
    When we create a material in MM01 , we can either create material as Internal Material No. or External Material No. (By Explicitly entering a material No.)
    Our requirement is that: When we create an Internal Material , there should NOT be any Leading Zeros in MATNR.
    and for External Material No.  , Leading Zeros Should be there.  (In Database)
    1) Now , we can create the No. Range for material in such a way that it will allow only AlphaNumeric entries for Internal Material , and Only Numeric Entries for External Material No.
    This should slove the Purpose.
    But According to the Client's requirement , Material No can be Numeric OR Alphanumeric for Internal As well as External Material No.
    2) We can Add or Remove leading zeros from MATNR at application level.  i.e.  we can find some BADI / Enhancement where we will Use the Conversion FM (CONVERSION_EXIT_MATN1_OUTPUT or  CONVERSION_EXIT_ALPHA_OUTPUT) and remove Leading Zeros from MATNR. But these changes will NOT reflect at Database Level , Because in MATNR Domain , there is a conversion Routine  , That will Add Leading Zeros in MATNR While saving in the Database.
    3) While Displaying the Material In SE11 , we can also set the "Display Format" as With leading Zeros OR Without Leading Zeros.
    But we dont want to Just "Display" material with OR Without Leading Zeros.  we want to actually create materials in that way.
    What can we do , so that at Database Level our changes are Reflected.
    Thanks and Regards,
    Anand Gore
    Edited by: anandgore on May 18, 2011 3:47 PM

    That will Add Leading Zeros in MATNR While saving in the Database.
    That is because you have it configured that way.  You can configure the storage as you desire.  The default is the behavior you are describing.  You, or your functional analyst, need to review the documentation on the MM config settings for material master number storage.
    Never use CONVERSION_EXIT_ALPHA_OUTPUT for material conversion.  Also keep in mind that the MATN1 functions have their own BADI for extended formatting...

  • BAPI to remove leading zeros from the serial number

    Hi All ,
    plz can anybody suggest me the alternative BAPI for 'BAPI_SERVNOT_MODIFY_DATA ',whose function is to delete the leading zeros,from the serial number.
    Thanks.

    Perhaps instead of using a BAPI you can code it like this.
    DATA:serial(10) TYPE n VALUE '0000340078',
    pos TYPE i VALUE 1.
    START-OF-SELECTION.
      WHILE pos <= 10 AND serial+pos(1) = 0.
        pos = pos + 1.
      ENDWHILE.
      REPLACE ALL OCCURRENCES OF '0' IN serial(pos) WITH space.
      WRITE serial.

  • How to remove leading zeroes of a coloumn in a table

    can someone tell me how to remove the leading zeroes in a table's coloumn .... its a NUMC  data type..
    i tried with abap statement shift leading zeroes, but its not working for me.... the sorting is missing..
    in properties is there any option to remove the leading zerores>
    niraja

    Hi Niraja,
    I am displaying a table with information from SFLIGHT. The CONNID field is of type NUMC and so it too used to contain the leading zeroes.  I so deleted the leading zeroes in my WDDOINIT method before binding the internal table to the context node. The table now does not display the leading zeroes as earlier. Find my coding as shown below:
    METHOD wddoinit .
      DATA: lr_node TYPE REF TO if_wd_context_node,
            wa_sflight TYPE ig_componentcontroller=>element_node,
            lt_sflight TYPE ig_componentcontroller=>elements_node.
      SELECT * FROM sflight INTO TABLE lt_sflight.
      LOOP AT lt_sflight INTO wa_sflight.
        SHIFT wa_sflight-connid LEFT DELETING LEADING '0'.
        MODIFY lt_sflight FROM wa_sflight TRANSPORTING connid.
      ENDLOOP.
      lr_node = wd_context->get_child_node( name = ig_componentcontroller=>wdctx_node ).
      lr_node->bind_table( new_items = lt_sflight ).
    ENDMETHOD.
    Regards,
    Uday

  • How to remove leading zero in a inputfield

    I have a inputfield UI element which is bind to a NUM type context.  When it display a number, it always come with leading zero, like '001'. Can anyone teach me how to remove the leading zero.

    http://help.sap.com/saphelp_nw70ehp1/helpdata/en/3a/2232666aeb45f4b759848a4caf9c8b/frameset.htm
    Use the Display leading zeros formatting option in the context attribute properties.
    The other option is to use a data dictionary domain for the field that has a built in field conversion exit. The ALPHA conversion exit is commonly used on NUMC fields like Sales Order number to suppress leading zeros.  The WD runtime will automatically use the underlying DDIC Domain Field Conversion Exit.  You don't need to do anything except use that DDic to define the context.

  • Remove leading zeros for invoice lists to allow auto lockbox processing

    I have a change request for the following document at my job. but i am very new into it and do not know how to start and what to do exactly? can anyone please help me what to do in this matter.
    SAP auto posting process for lockbox checks was created to post cash with minimal manual intervention.
    Transaction FLB2 is used to import a lockbox file from Bank of America containing customer payment detail to auto match and clear invoices in the AR subledger. The auto post program tries to match an invoice number from the Reference field to the invoice # in the lockbox file which does not have any leading zeroes. In order to allow this match to happen a user exit was developed to remove any leading zeros from the Reference field in the invoices It works fine for regular invoices but not for the invoice lists u2013 invoice numbers in the 76xxxxxx range. The leading zeros are not removed there, so these invoices fall out of the auto posting process. It has been expressed that we need to improve our automated check posting hit rate for better efficiencies, and to do so we need to have these invoice list invoices fixed in the same way as the regular invoices are.
    please advise
    Vishal

    can anybody please answer it?

  • How to remove leading Zeroes in all fields in Payload

    Hi,
    How can I remove the leading Zeroes in every Filed I have in whole Payload Structure.there are around 10000 fields that have to be removed the leading Zeroes.any good idea please.
       <POSNR>000010</POSNR>
      <MATNR>000002465640</MATNR>
      <ARKTX>000012 KG D107</ARKTX>
      <MATKL>00030010000</MATKL>
      <WERKS>0000ORGC</WERKS>
      <LGORT>0000GC55</LGORT>
      <CHARG>000TEST</CHARG>
    like this mutliple segments and multiple Fields.so  I can take as whole payload with multiple fields should not have leading Zeroes.I can handle if they are 10 0r 20 fileds,but not like whole pay load/1000 fields right.
    thank you,
    Prem

    Hi
      You can have an additional XSLT mapping, to your existing one..
    use copy-of & apply-templates to copy the whole tree & make changes recursively.
    below is a sample code , the marked line is where you need to try your logic of trimming Zeros. (this code does upper case)
    add this below code in your interface mapping object, as XSLT mapping, which does the job (only try putting your logic)
    <xsl:stylesheet
                      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                      version="2.0">
                <xsl:output  method="xml"
                            indent="yes"
                            omit-xml-declaration="yes"/>
                <xsl:template  match="*">
                      <xsl:copy>
                            <xsl:copy-of  select="@*"/>
                            <xsl:apply-templates/>
                      </xsl:copy>
                </xsl:template>
                <xsl:template  match="text()">
                      <xsl:value-of  select="upper-case(.)"/>
                </xsl:template>
          </xsl:stylesheet>
    hope this fixes your issue
    Regards
    Vishnu

  • How to remove leading zeroes on form.

    Hi all,
       Is there a way that I can remove the leading zeros that come along with the Serial number from showing in my form.
    i.e for example: the value of &QALS-EMATNR&
    Actual value in the databse table is : "0280012380",
    Printing value on the form is            : "000000000280012380",
    Now I should get the actual value of the field EMATNR
       I had tried with the ways like..
    &QALS-EMATNR(Z)&
    &QALS-EMATNR(CIZ)&
      Is there any aternatives???
    Thanks,
    Surender.

    Hi
    If you print 000000000280012380 it means the value in the variable QALS-EMATNR is 000000000280012380.
    The field EMATNR has MATNR as domain, this is a type char long 18, it has the routines  MATN1 for input/output convertion and that routine doesn't delete the leading.
    I think the option Z works for type number only, so u need to delete the leading zero before printing the data.
    So just as somebody said u can use the fm CONVERSION_EXIT_ALPHA_OUTPUT in order to convert the output format, u should use it in driver program:
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
           EXPORTING
                input  = QALS-EMATNR
           IMPORTING
                output = QALS-EMATNR.
    If you can't change the program, u can create a routine (form) in a new program and call it by the sapscript:
    /: PERFORM DELETE_LED_ZERO IN PROGRAM ZPROGRAM
    /: USING       &QALS-EMATNR&
    /: CHANGING &QALS-EMATNR&
    /: ENDPERFORM
    * &QALS-EMATNR(Z)&
    So create the new program where defining the routine
    FORM DELETE_LED_ZERO TABLES IN_TAB   STRUCTURE ITCSY
                                                            OUT_TAB STRUCTURE ITCSY.
      DATA: MATNR TYPE MATNR.
      READ TABLE IN_TAB  WITH KEY NAME = ' QALS-EMATNR'.
      IF SY-SUBRC = 0.
        MOVE IN_TAB-VALUE TO MATNR. 
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
              EXPORTING
                   input  = MATNR
              IMPORTING
                  output = MATNR
        READ TABLE OUT_TAB  WITH KEY NAME = ' QALS-EMATNR'.
        IF SY-SUBRC = 0.
           MOVE MATNR TO OUT_TAB-VALUE.
           MODIFY OUT_TAB INDEX SY-TABIX.
        ENDIF.
    ENDIF.
    ENDFORM.
    Max

  • How to remove leading zeros from the screen?

    Hello friends,
    I am working on dialog programming.
    I have a field with is NUMC 13. so when value is populated, It removes the leading zeros.
    How can I display the my value with leading zeros on the screen painter?

    Call SE51, layout, double-click on field, attributes, tab Program, check Leading zeros.
    Regards,
    Raymond

  • How to remove leading zeros and leading blanks from numc

    Hi experts,
             i wanted to show personal number into my smartform..The field name is PERNR(8) which is of type N. But, in my smartform I get output as (000234)..if I use &pernr(Z)& leading zeros r removed but then the output is (   234)..Now, I wanted to remove this leading space also...
    please tell me the solution for this...
    thanks

    Hi Ujjwala,
    You can use SHIFT.
    DATA: V_CHAR(10) VALUE '00000'.
    SHIFT V_CHAR LEFT DELETING LEADING '0'.
    Regards,
    Ramesh
    *award the points if answer was helpful

Maybe you are looking for

  • Adobe pdf can not be completedly displaced by Adobe reader XI while it is inserted into a Excel2013(office 365) file

    adobe pdf can not be completedly displaced by Adobe reader XI while it is inserted into a Excel2013(office 365) file

  • OB58 hierarchy

    Hi, In transaction OB58, we see a hierarchy of account groups and G/L accounts if we expand the nodes. How do I get the hierarchy technically if I have to use it in a report. In which tables does it get stored or there are any standard FM's to get th

  • Commission agent issue

    Hi guys,     Can any one hlep me out,my cleints wantss us to add comison agent for evey order, how exactly we need to map this scenario in partner function determination. Thanks

  • DVCPRO HD export mystery

    I had super16 film footage that was transferred on a Spirit to SonyHDCAM at 23.98 and loaded into final cut as DVCPROHD 1080i60 (HD1280x1080) 23.98. No problems. The edit went fine. The whole thing went to Shake for dust removal and camera jitter rem

  • Issue regarding ck11n

    Hi guru: When I create material cost estimte for finish goods XXX,i encountered below issue: msgno 213 cost component structure z1 is not active             168 cost estimate for material 121 /plant 1000 is incorrect             240 cost component sp