Including blank spaces to the field

Hi,
I have a field in the internal table with length 10.
If this field is blank, i want to assign 10 spaces in that field.
how to do tht.
plz help.

Hi,
Hope below code will be useful for u.
data: v_dt type d value '        '.
i given 8 spaces here becoz length of d is 8. likewise u can use ur Internal table
write: 'date',v_dt.
Reward if helpful....
Regards,
vijay

Similar Messages

  • How to Remove Blank spaces in the text elements for a smartform

    Hi All,
    Can any one please help me out to remove the blank spaces in the text elements.
    We are printing Labels using the Zebra Printer and we have rotated the windows to 90 degrees.
    We are able to see out text and barcodes. But the issues is when we are printing the label. We are getting spaces in the Text and in the Text elements fields. I have tried to give &g_name(C)&. But it is not working even i worked with style sheet spaces no luck.
    Currently out text and fields are printing like this
    s h r i y a n
    material number
    1111  -001  -000
    They should print like
    shriyan
    1111-001-000
    According to the ZEBRA suggestions we are using the font helve.
    Plase help us it is very urgent.
    Reward point will be given.
    Thanks

    Hi,
    Just use Condense g_name inside the program lines.
    Just to see how it behaves put a hard breakpoint.
    Break Username. and check the condense statement.
    condense <your field> no-gaps.
    Create program lines ahead of printing. give the field you want to condense in the input and output parameters of the program lines.
    Use condense inside the program lines.
    Thanks,
    Vamshi.

  • Blank Spaces in the report

    <p>Hi </p><p>My Report has some columns which has the option as "Can Grow" so that when the returned value from the database is more that one line it can accomdate the data in the field.</p><p>The problem i am facing is that when the records are printed in the pages and when the next record is unable to fit in the remaning section of the report it automatically pushes to the next page.<br />In this scenario the previous page has blank space after the next record is printed.</p><p>Is there way that i can suppress this balnk space and force teh record to be printed in the same page and when the page is over it follows in the next page.</p><p>Thanks in Advance<br />Moa</p>

    <p>My problem was that I wanted to display several lines in a total field: order amount, minimum charge, delivery charge and tax. When any of them was zero, I needed to hide it without leaving a big gap. </p><p>Here was the solution: </p><p>Create a textbox. Set the textbox&#39;s "Suppress blank lines in embeded fields" property. <br />Instead of using database field (for example, table.fieldValue) and a label, create a formula that says:  </p><blockquote><p>If isNull{table.fieldValue} then </p><p>    "" </p><p>else </p><p>"Value:" + Chr(9) + ToText({table.fieldValue})   </p></blockquote><p>I placed a tab in this formula to space it out. Add tab stops (one left-aligned, one decimal) to your textbox, and drag the formula into it (embed) instead of the database field. Add the other fields to the textbox as well, separating fields by adding carriage returns. Bingo. The field and the line will disappear when there is no data.</p><p> I hope this helps.</p>

  • HT202879 Since opening an existing Pages doc, all the previously centred images and tables are now too far to the rights - leaving a large blank space to the left of each page. Any ideas reducing?

    Since opening an existing Pages doc, all the previously centred images and tables are now too far to the rights - leaving a large blank space to the left of each page. Any ideas re fixing this?  Problem remains even when I open an earlier version on the previous version of Pages

    It has always been that the upgrade tries to be the "master" over the older version.
    Anyway in Pages 09 you have probably the Comments field showing, making all contetn to move to the right.
    Go to View menu > Hide Comments.

  • How do I get rid of the blank space at the bottom of the new Firefox menu?

    The new firefox 4 has a different menu system. IT has blank space at the bottom wiht just a plus sign that opens new tabs. I can get that from the + sign by the tabs and don't want it or the rest of the blank space on the bar. I need all the space in the main window I can get. How do I get rid of this?
    Found my own answer, disable Conduit Engine toolbar, whatever the heck that is. Why it's enabled to start with is beyond me.

    Hi stephanie,
    These are unrelated questions/statements.
    Space before and space after a paragraph are controled in the Text Inspector, as you've found out.
    Pages will create a page break whenever there is no room for another line on the page. That break can come anywhere in a paragraph.
    You may be thinking of Widow and Orphan prevention, and the other Pagination controls, found under the More button in the Text Inspector. (If that's what you found, then thanks for the refresher! I hadn't been to that pane for awhile, and had forgotten the variety of pagination controls available.
    Regards,
    Barry

  • How to set white spaces between the fields in dataset??

    Hi all,
    I am writing a set on information to from infotypes to a text file. Its a fixed width file. How do set white spaces in the fields for dataset?
    Example:
    TYPES: begin of header,
                    filler(40)  type c,
                    id(3)        type c,
                    filler2(7) type  c,
                    delimiter  type  c,
                 end of header.
    DATA header type header.
    header-filler1 = ' '.
    header-id       = '100'.
    header-filler2 = ' '.
    header-delimiter = cl_abap_char_utilities=>newline.   ( do it to get a new line)
    my_table = header.
    append my_table.
    DATA: out_file(256) type C,
          codepage_ref type ref to CX_SY_CONVERSION_CODEPAGE,
          out_char type c,
          size type i,
          insert_string type string,
          insert_size type i.
      out_file = filename.
      open dataset out_file for output in text mode ENCODING NON-UNICODE.
      LOOP AT my_table.
        size = strlen( my_table ).
        insert_string = ''.
        DO size TIMES.
          offset = sy-index - 1.
          try.
              out_char = my_table+offset(1).
              IF out_char = SPACE.
                CONCATENATE insert_string '' INTO insert_string SEPARATED BY SPACE.
              ELSE.
                CONCATENATE insert_string out_char INTO insert_string.
                transfer insert_string to out_file NO END OF LINE .
                insert_string = ''.
              ENDIF.
            catch CX_SY_CONVERSION_CODEPAGE.
              insert_size = strlen( insert_string ) - 1.
              insert_string = insert_string(insert_size).
          endtry.
        ENDDO.
       transfer CL_ABAP_CHAR_UTILITIES=>NEWLINE TO out_file NO END OF LINE.
      ENDLOOP.
      close dataset out_file.
    How do I get to insert the space for filler1 and filler2?
    Edited by: Siong Chao on Oct 4, 2011 4:56 AM
    Edited by: Siong Chao on Oct 4, 2011 8:27 AM
    Edited by: Siong Chao on Oct 4, 2011 8:29 AM

    problem lies in the open dataset codes
    Used:
    open dataset out_file for output in text mode encoding non-unicode message msg.
    if sy-subrc= 0.
    loop at my_table.
    transfer my_table to out_file
    transfer cl_abap_char_utilities=>newline to out_file no end of line.
    endloop.

  • When I print a Word document to a shared printer, print preview looks fine but the printed page has too much blank space at the top and doesn't print the bottom few lines.

    When I print a Word for Mac document to a shared printer (that is connected to my iMac) from my Macbook Pro, print preview looks fine but the printed page has too much blank space at the top and doesn't print the bottom few lines.  I have tried to adjust the margins and the page setup settings but to no avail.  It used to print fine until recently.  Is there a way to fix it so that the printer prints what print preview shows?

    I should add that when I e-mail this document to myself and print it directky from the iMac, it prints fine.

  • Blank space in the report detail section

    Hi ,
    I have data for ten columns and after that i am getting a blank space, so my report is scrolling to right side without any data.How shall i remove the blank space.Any suggestions.For one more i am getting this only at the second page (Detail section)
    Regards,
    Rajasekar

    Thanks James for the reply,but i am not getting it correctly.
    I have a year column which is the last column in my detail section.If i don't get any value for that year column then i am not getting these blank space at the right side of my report.If i have value for the year column then i am getting blank space double the times to my report detail section.
    Any suggestions
    Regards,
    Rajasekar

  • How can I fill the blank space in the example below?

    I have to fill using sql statement the blank space with the same description that appears below that belong to the same STTCKT. I
    am using a temporary table.

    There is no need in ROW_NUMBER. You can use simple query like below sample which cost 6% relative to the use of ROW_NUMBER which cost 94% (sort is havy operation with no index).
    DDL+DML:
    CREATE TABLE test( [STBK#] varchar(50), STTCKT int)
    truncate table test
    Insert into test values
    (null, 48035)
    ,('First Two Truck', 48035)
    ,(null, 48039)
    ,('First Two Truck', 48039)
    ,(null, 48046)
    ,('First Two Truck', 48046)
    ,(null, 48054)
    ,('KLS LOGISTIC, INC.', 48054)
    GO
    select * from test
    GO
    If all you need is SELECT with FILL then check this:
    select
    --[STBK#] ,
    STTCKT, [Fixed_STBK#]
    from test T1
    Cross APPLY (SELECT TOP 1 T.[STBK#] FROM test T WHERE T.STTCKT = T1.STTCKT and T.STBK# IS NOT NULL) T2 ([Fixed_STBK#])
    And you can use this query as well without CROSS APPLY
    select
    --T1.[STBK#] ,
    T1.STTCKT, T2.[Fixed_STBK#]
    from test T1
    LEFT JOIN (SELECT T.STTCKT,MAX(T.[STBK#]) [Fixed_STBK#] FROM test T GROUP BY T.STTCKT) T2 ON T1.STTCKT = T2.STTCKT
    If you are looking for update the original table please check this:
    UPDATE test
    SET [STBK#] = T2.[Fixed_STBK#]
    FROM test T1
    Cross APPLY (SELECT TOP 1 T.[STBK#] FROM test T WHERE T.STTCKT = T1.STTCKT and T.[STBK#] IS NOT NULL) T2 ([Fixed_STBK#])
    WHERE T1.[STBK#] IS NULL
    GO
    I hope this is helpful and answer your need, If not please try to clrify your needs and post your DDL+DML
    [Personal Site] [Blog] [Facebook]

  • How do I delete the blank space at the beginning or end of a project?

    I constantly end up with blank space at the beginning or end of a project - how do I remove it?  I get this ALL the time and I jsut can't get rid of it.  Obviously I want my project to start at 0.00 not at 1.xx.
    Thanks.

    That's not a project. You're inside an multicam angle editor. You need to edit the multicam clip into a project. That's where you edit it.

  • Change Filenames with blank spaces in the Filename

    I want to change many filenames with blank spaces and replace
    blank spaces with underbar character.
    Example:
    File One change to File_One
    File Two change to File_Two
    Here is my script:
    for file in `ls`
    do
    i=`ls -1 *" "*`
    b=`ls -1 *" "* | sed -e s/\ /_/g`
    done
    mv "$i" $b
    Please advise what is wrong with my script that isnt
    working. The script works if I only have one filename
    with a blank space. But if I have several filenames
    with blank spaces in the name then it doesnt work.

    I want to change many filenames with blank spaces and replace
    blank spaces with underbar character.
    Example:
    File One change to File_One
    File Two change to File_Two
    Here is my script:
    for file in `ls`
    do
    i=`ls -1 *" "*`
    b=`ls -1 *" "* | sed -e s/\ /_/g`
    done
    mv "$i" $b
    Please advise what is wrong with my script that isnt
    working. The script works if I only have one filename
    with a blank space. But if I have several filenames
    with blank spaces in the name then it doesnt work.

  • How  can i check the space in the field.

    hi:
    how  can i check the space in the field.!
    for example:
    data: string(30) type c value 'sent ence'.
    search  string for space.
    if sy-subrc = 0.
    write: 'i am right'.
    endif.
    but the result is that it cann't check the space.
    so how can check the space in the field!!
    thank you very much!

    Hi,
    data: v_string(30) type c value 'sent ence'.
    DATA : v_cnt TYPE I,
                v_num TYPE I  VALUE 1,
                v_num1 TYPE I.
    v_cnt =  strlrn( v_string ).
    DO v_cnt TIMES.
      IF v_string+v_num1(v_num)  EQ SPACE.
        write: 'i am right'.    
    ELSE.
       write: 'i am WRONG'.
      ENDIF.
      v_num1  =  v_num1 + 1. 
    ENDDO.

  • Pages and numbers will not take dictation and iOS 8. Very frustrating screen goes blank no keypad. I have to close the document In order to get rid of the big blank space where the keyboard should ber

    Pages and Numbers will not take dictation in iOS 8 on my iPad 4 and iPad mini.
    Very frustrating -screen goes blank where keyboard should be when I touch the microphone- no keypad & dictation does not record. I have to close the document In order to get rid of the big blank space where the keyboard should be. When is this going to be fixed?it's making recordkeeping Pages and Numbers,  which I use heavily, almost impossible.
    also dictation in other locations such as Mail put capitals in the middle of sentences and sometimes don't capitalize first letter in a sentence (see first letter of this sentence!) and other instances like the months of the year or the days of the week. Is anyone else having these problems?

    Pages and Numbers will not take dictation in iOS 8 on my iPad 4 and iPad mini.
    Very frustrating -screen goes blank where keyboard should be when I touch the microphone- no keypad & dictation does not record. I have to close the document In order to get rid of the big blank space where the keyboard should be. When is this going to be fixed?it's making recordkeeping Pages and Numbers,  which I use heavily, almost impossible.
    also dictation in other locations such as Mail put capitals in the middle of sentences and sometimes don't capitalize first letter in a sentence (see first letter of this sentence!) and other instances like the months of the year or the days of the week. Is anyone else having these problems?

  • Blank spaces at the end of an IDoc text field get lost when posted to R/3

    Hi Guys,
    I am facing the following issue:
    In an XML file-to-Idoc scenario, there are spaces at the end of a text field in the inbound XML file, which I can see when I open the inbound file with a text editor like notepad, and they are kept after XI mapping is executed (I can see them in message mapping simulator). However, it seems that these spaces get lost once the IDoc is posted to SAP R/3 and they are not visible on SAP R/3 side.
    Do you have any idea ? Thanks.
    Best Regards,
    Evaggelos Gkatzios

    That means SAP is removing the spaces from IDoc fields, where you spaces are not allowed. Does it create any problem?
    Thanks,
    Nabendu.

  • Simple??? Want "INSERT" function to return blank space after a field, how?

    All,
    Am I just having a brain fart? I have a situation where I have a field that needs to return just one space, or a value that has a space before and after it.
    Example:
    In the text ==> I am<field>going to the office. <-- notice no space between am, <field> and going
    I want it to say if FALSE, then "I am *not* going to the office."
    If true, then "I am going to the office."
    If true, I'm simply RETURN(""); <-- This returns a blank space
    If FALSE, I have tried:
    ret="not"
    RETURN(" " & ret & " ");
    This returns "I am notgoing to the office". <-- Notice no blank space after "not"?
    I've tried
    ret="not";
    ret2=(" " & ret);
    RETURN(Insert(ret2, 3, " "));
    Still the same result. What's strange is, if I do a RETURN(Insert(ret2, *2*, " "));, then it returns "I am no tgoing to the office" <-- Notice the space between the "o" and the "t"?
    Ideas?

    Trailing spaces are often removed from data. In your case, the easiest thing to do will be to use what is called the "hard space" character instead of a "real" space. This is key code ALT+0160. For all intent and purposes, it looks like a space and will print as a space, but since it is not technically the space (0032) character, it will not be trimmed from your projects. Just open the quotes, turn off the NUMLOCK and hold down the ALT key and type 0160 and then release the ALT key. This will add the hard space into your string. Then if you are like me, you will have to remember to turn the NUMLOCK back on.
    " not "
    I'm not sure how this will post into this message, but the example above is using hard space characters.
    Edited by: user9976634 on Dec 5, 2012 12:52 PM

Maybe you are looking for