Removing zeros on the excel download

I wanted to know how we can remove zeros from the kebtr at the excel download through ALV without converting it to a type c. for now I am converting it to type c and then validating it this way :
if tb_main-kebet = 0.
    tb_main1-kebtr = space.
  endif.
But because of this the formats are not ok and user insists that it should be a numberic field for him.
Thank you very much.

Hello Kris,
I am able to see the data properly in XLS File.
Use fieldcatlog no_zero = 'X'.
Now run the transaction -> click on XL Icon ( if you do not get the data properly using navigation),now see the results here.
you can save same xls file into local machine too.
Thanks
Seshu

Similar Messages

  • Need leading Zeros in the excel sheet which is sent from ABAP

    Hi ,
    I am downloading data from SAP to excel sheet using the WS_DOWNLOAD Function Module. The numeric data in not having leading zeros.  if it is 0010 it is displaying 10 in the excel sheet . i need the leading zeros in the excel sheet. without manulally changing it to Text in the excel sheet .
       Is there any way to do it .
    Thanks,
    Chetan

    Hi Chetan,
      CALL FUNCTION 'WS_DOWNLOAD'
        EXPORTING
          filename                = w_file_path
          filetype                = 'DBF'                       "declare the File type as DBF then leading zeros will appear
          write_field_separator   = 'X'
          confirm_overwrite       = 'X'
        TABLES
          data_tab                = Itab.
    Regards,
    Prabhudas

  • Removing zeros at the begining

    hi,
    How to remove zeros at the begining of a variable value irrespective of the length of that number
    for example,
    data:var type int4.
    var = '0000012434'.
    var= '0003423365'
    var= '0436509843'.
    I want to remove all zeros at the beginning.
    the purpose is I am passing this to a function module which can not allow intial zeros.
    Please help me with code

    Hi,
    CONVERSION_EXIT_ALPHA_OUTPUT
    converts any number with zeroes right into a simple integer.
    Ex:
    '00001234'-->1234
    CONVERSION_EXIT_ALPHA_INPUT
    converts any number into a string fill with zeroes, with the number at the extreme right
    ALPHA conversion is used especially with account numbers. During conversion from the external to the internal format, the system checks to see if input in the INPUT field is purely numeric, that is, if this input consists only of numbers, possibly with spaces before and after them. If this is the case, then the number string is inserted right- justified in the display field OUTPUT and all spaces to the left of the value are filled with zeroes ('0'). If the input is not purely numeric, it is inserted in the display field from left to right and all extra spaces are filled with blanks.
    Example:
    (Input field and output field are both eight characters in length)
    '1234 ' --> '00001234'
    Regards,
    Omkaram.

  • Preceeding zeros disapprearing in the excel download.

    I have programmed ALV report using function module REUSE_ALV_GRID_DISPLAY.
    I have declared my final output internal table's  batch field as CHARG_D which is of 10 characters.
    I have passed field_catelog-no_zero = 'X'. for batch field.
    However when I download into excel sheet, preceeding zeros of batch disappearing in excel sheet.
    Is there any way to retain the preceeding zeros for batch values and other similar fields values  in the excel sheet after download ?
    THANKS IN ADVANCE.

    There's a few variations on how to get the data from ALV into Excel and I don't have a system right now, so I can only give a general comment. If the direct export to Excel (OLE) doesn't work, I'd recommend to export the data as local file using format Spreadsheet and give it an extension like ".csv".
    When saving the file this way, it really is just a tab separated file (text file, you can view it via Notepad and check for the leading zeros), which you can open in Excel. However, you have to be careful, because when you double-click on the file, Excel will usually open the file directly and format your batch (CHARG_D) field with type General. As a result anything that looks like a number, will be stripped off the leading zeros. Therefore instead you should open the data via the import wizard (e.g. in Excel 2007 it's on the Data ribbon under Get external data and then choosing From text) and reformat the field CHARG_D from General to Text. This will ensure that you'll keep the leading zeros.
    There's lots of other ways to do it and my version is probably not the most efficient. However, it works in general, as long as you see the leading zeros in the ALV and is easy to remember (at least for me)...
    Good luck, harald

  • Placing zeros in the excel file

    Just a quick question, when I tried to use "write file" component of transactions to append data (eg. 00012345) to .csv file, Excel automatically converted it from "00012345" to "12345" .  but i unable to display as '00012345'.in the excel file. can any one resolve the solution.

    Hi,
    I dont understand why people don't search before posting the question, It can save your time,
    Even this question is being asked yesterday....
    Re: csv with leading zero
    It is not possible in XL, its a default property of XL to avoid leading zeros.
    If you are able to do that then that is only possibe by doing formating of cells in XL.
    Thanks,
    Krishna...

  • Removing zeros after the decimal point       Reply with quote

    I want to remove the zeros after the decimal point, that this be done?
    Например, Example,
    120.000 => 120 120.000 => 120
    120.300 => 120.3 120,300 => 120.3

    hiiiiiiii sweetsoni,
    try this may it helpful for you
    SHIFT string RIGHT DELETING TRAILING '0'.
    SHIFT string RIGHT DELETING TRAILING '.'.
    for example
    DATA: v1 (6) TYPE c VALUE '100 .000 ',
    v2(6)  TYPE c VALUE '100.200'.
    SHIFT v1 RIGHT DELETING TRAILING '0'.
    SHIFT v1 RIGHT DELETING TRAILING '.'.
    SHIFT v2 RIGHT DELETING TRAILING '0'.
    SHIFT v2 RIGHT DELETING TRAILING '.'.
    ultimately
    v1 = '100',
    v2 = '100.2'.
    Moderator message: question and answer copied from external source, points deducted, do not repeat!
    Edited by: Thomas Zloch on May 19, 2010 2:14 PM

  • How to hide/remove a column from Excel download file

    All,
    I have about 7 columns iam displaying on my IR but there is 1 column on this report i dont want to appear on excel download file. How do i accomplish this?
    apex 4.1.0/theme20/report region,
    thanks in advance,

    Hello,
    For IR, each download format is associated with specific REQUEST value. For CSV files, its CSV. So you can put the condition for columns using :REQUEST value as follows.
    Goto Report Attributes -> Select Column you want to hide for CSV export -> Conditional Display
    Condition Type- PL/SQL
    Expression1- :REQUEST IS NULL OR :REQUEST != 'CSV'
    Regards,
    Hari

  • Removing zeros from the application

    hi, we have several users that have loaded zeros instead of blanks or #missing into their webforms and have lots of zeros that are taking up needless space. i was originally thinking of locking and sending #missing where there are zeros, but have realized this will be a very long chore. we have mitigated the issue with users by changing "0" into blanks in user's excel sheets before pasting results in their sv webforms but i'm most concerned about data already in the db.
    what would be the best course of action? could we create a calc script that could replace the "0"s with #missing? that seems like an easy solution if we know the correct syntax and all that good stuff. i pose this question as i imagine others have seen this issue and probably know a really good fix.
    we are on planning and EAS 9.3 as our administrative tools. please let me know if you need additional info.
    thanks, tom

    There are two options that come to me
    1. Export the data in column format and create a rules file that converts zero values to #missing when loading. This way you have a backup in case anything goes wrong
    2. Write a calc script on a dense member where it divides by itself. Something like Local = Local/Local * Local; Any division by zero is #missing. Of course you have to pultiply by the value to get the original value back
    5/5 * 5 = 5
    0/0 * 0 = #missing
    If you do the first option, you would have cleared the database so the reload will defrag it. IF you do the second option, you will need to run a forse restructure to reep the benefits.

  • Problem with the Excel Download with GUI_DOWNLOAD

    Hi Sdn,
    I am reading the long text from FM READ_TEXT and downloding that text to Excel file  in one cell with the GUI_DOWNLOAD FM (I got 16 lines of text and by using CONCATENATE i got 16 lines of text into a string variable).
    The problem here I am facing is.
    The text contains a # symbol in one line (Which is not a last line).
    After downloading the file the text after the # symbol is coming in the next line.
    I tried to REPLACE that # symbol with space but failed.
    System not at all reading that symbol also.
    The text came as LEE, ANDREW" Completed On: 2010/09/04#
    Can any one help me to solve this issue.
    Edited by: Naresh Nelapatla on Apr 20, 2011 8:27 PM

    Hi Naresh,
    My thoughts on a possible solution, convert the last character value to a HEX value and check if it falls within the ASCII/Unicode CP range, Obviously this becomes easier if you are just looking at a single language character set.
    The below FM and code helps you check if the character falls within the ASCII char set.
    DATA: l_in_char TYPE string,
          l_out     TYPE xstring.
    CALL FUNCTION 'NLS_STRING_CONVERT_FROM_SYS'
      EXPORTING
        lang_used                   = sy-langu
        SOURCE                      = l_in_char
      TO_FE                       = 'MS '
    IMPORTING
       RESULT                      = l_out
      SUBSTED                     =
    EXCEPTIONS
       illegal_syst_codepage       = 1
       no_fe_codepage_found        = 2
       could_not_convert           = 3
       OTHERS                      = 4.
    IF l_out LT '0' OR l_out GT '7F'.
      WRITE: 'error'.
    ENDIF.
    Links: http://www.asciitable.com/
              http://www.utf8-chartable.de/unicode-utf8-table.pl
    Regards,
    Chen
    Edited by: Chen K V on Apr 21, 2011 11:25 AM

  • How to hide the coloumns in the excel download Using I_OI_SPREADSHEET

    Hi,
    How to hide or delete the coloumns which are not containing any values ,I am using interface  I_OI_SPREADSHEET.
    There is a method in this interface HIDE_COLUMNS please let me know if any body knows how to use this method to hid the coloumns in the spread sheet download.
    Thanks in advance,
    Regards,
    Venu

    Hi,
    You just define first column and last column you want to hide from method:
    CALL METHOD go_excel->go_spreadsheet->hide_columns
      EXPORTING
        name     = 'test'
    *    no_flush = ' '
        first    = 2 "you want to hide row 2nd and 3rd
        last     = 3
      IMPORTING
        error    = go_excel->go_error
        retcode  = go_excel->gc_retcode.
    Regards,

  • Replace Function removing Zero from the end.

    Hi ALL,
    I'm runing following query
    select REPLACE(52000.50,'.') from dualwhich is giving me output as
    *520005*
    But I need last zero also in the output. like *5200050*
    Please help me if you have any solution.

    user2988171 wrote:
    Thanks it worked only small chane in the above query..
    select REPLACE(to_char('52000.50','999999.99'),'.') from dual Edited by: user2988171 on Jul 30, 2010 4:38 PMYou broke it again.
    If you have a string and not a number right from the beginning then there is no reason to use TO_CHAR.
    Simply run
    select REPLACE('52000.50','.') from dual;Or use the correct version from Toon if you enter a number value.
    Btw. If it is a number you could also simply muliply it by 100.
    select 52000.50 * 100 from dual;Edited by: Sven W. on Jul 30, 2010 2:58 PM

  • How to remove the available downloads from iTunes???

    Please I need to remove the Available Downloads from the iTunes as I did download some podcasts and every time they gave me an error in downloading them and can't niether complete nor remove them from the available downloads...

    Thanks alot

  • Leading zeroes dropped in Excel

    Hello folks
    I've got an issue with using downloading data onto an Excel file using the FM GUI_Download. The leading zeroes of the PERNR field get truncated when opening the file with MS Excel.
    However the zeroes are in place when the downloaded file is opened with notepad or any other text editor.
    Is there any solution to prevent Excel from dropping the leading zeroes.
    I'm currently using tab as the field separator, and have defined the PERNR field as TYPE C at the internal table used for populating and displaying the data.

    Hi,
    data:matnr(20) type c.
    concatenate text-001 g_t_ekpo-matnr into g_t_ekpo-matnr.
    text-001 is having '.
    I had declared the Matnr as type c so that it can accomodate that single quote.It is indeed downloading the matnr with preceeding zeroes into the excel but along with the single quote.Can't we get the preceeding zeroes into excel without the single quote into the excel.
    Thanks,
    Kiran.

  • Excel Download of a Web SAP BW Report asks userid and password.please help

    Dear BW folks,
    Issue: When I run a specific SAP BW Report from Web and download the same into excel & csv.
    When I open the excel file downloaded, it asks me user name and password to enter. csv file downloaded doesn't ask.
    The report has 0cust_sales hierarchy and SBU hierarchy.
    Is there any thing to do with these hierarchies that the excel download is asking user name and password?
    Please help me out!!!!! This report needs to be downloaded into excel sent to my manager.....
    Regards
    Pavan

    Hi Pavan
    It is possible,please refer the below link
    Report execution without prompting user id
    Providing un-secured access to a web report.
    Also, for the time being, you can run the query and save a workbook and sent across
    These will resolve the issue
    Thanks
    Pavan Agarwal

  • Remove zeros in LOVs of BW Infoobjects on Webi report

    Dear Experts,
    My BW infoobjects(0GL_ACCOUNT) showing preceding zeros in the BI4.1 WEBI Prompts LOVs, so user don't want the zeros and they need only values and also they compare BEx analyzer with BO since BEx analyzer LOVs shows only values without zeros.
    Is there any function or setting either in BO or BEx designer to remove zeros in the BW infoobjects? so that in BO LOVs display only values without zeros.
    Currently values is 0000123456 in BO LOVs and user want only 123456 as per BEx analyzer.
    BEx query as semantic Layer
    Platform: BI4.1 SP01
    BW: BI7.3 SP6
    Please help
    Thanks in advance.
    Regards
    Karuppiah N

    Hi
    Try to make use of custome display fomrat option in business layer.
    Find the below link for custome date format...same process for Numeric objects also
    BI4.1 Business Layer Enhancements - Create Display Format

Maybe you are looking for

  • Diff b/w "Customer exits" and "User-exit"

    Hi, What is the difference b/w customer exits and user-exit and also please explain me what are the various types of customer and user-exits. Thanks in advance. Ramana

  • Doesn't like some of my MIDI?

    Hiya! I'm using Logic 9 on my Black Macbook, running 10.5.8, with a Roland TD-4 set, and an M-Audio Fast Track Pro USB interface. My problem doesn't really make sense to me. I've recorded a drum track using the kit with the Superior Drummer 2.0 plug-

  • Table for asset master layout

    Hi In asset master layout setting, we tell system which all fields needs to be made mandatory at the time of creating asset master. This setting we do at screen layout and this screen layout is assigned to asset class. I want to know table where i ca

  • Family Sharing no Match or Radio?

    I spent a good bit of time setting up sharing only to find out it doesn't share two big iTunes features: Match/Imported Music/CDs and Radio without Ads. It appears that Family Sharing does not include the vast library of CD's I have uploaded to iTune

  • Adobe After Effects Multiple instances does not working parallel using Scripting

    Hi all, i am uploading after effects template to my site, user came and upload his desired contents. i update the template using scripting with user's contents and then render video so user get video with his uploaded text/images etc. its working per