The command to substitute word spanned in two lines

What is the command to substitute word spanned in two lines, for example, from -
test te
st1 tetst
to:
test te
st test
in which '1' is left out.
Can sed do this?
I tried sed /te^n st1/te^n st/g'. It does not work.
Thanks.

Yes, sed can do this. You need to build up a multi-line pattern space, so you are going to have to learn more sed than you want. Multi-line pattern spaces are explained in the "sed and awk" O'Reilly book. The sed man page is useless.

Similar Messages

  • Help reqd for printing the word text into two lines(AMOUNT in Rupees)

    Hi all,
    Im working for cheque printing and in the Amount in words column....im getting the text in a single line...as i've made it as in my script.
    (im moving the rate in to amount thru FM "HR_IN_CHG_INR_WRDS"....
    and it displaying into a single line....)
    But in every bank cheque...we have only a limit space for the first line and balance words should come in to the next line....How to achieve this in my form print.(when im giving the cheque(laser print) inside the printer for print)...
    *******FYI..
    now im getting it as
    RUPEES Ninety Seven Thousand Thirty seven and four paise only.(its going out in my cheque as it's coming in a single line,going beyond the words column)
    the above one...i want to print it as two lines as like in normal cheque...
    what condition i've to give and how to split the text or make it to continue in the second line....
    Pls do the needful with any examples or any coding.....
    help needed
    thanks & regards
    sankar

    hi Nehal,
    the below one is my coding part........FYI
    DATA AMT LIKE REGUD-WAERS.
    data: words(120) type c,AMOUNT(120).
    data: ant like PC207-betrg,t like reguh-vblnr,t1 type int4.
    FORM WORDS TABLES intab
    STRUCTURE itcsy outtab
    STRUCTURE itcsy.
    READ TABLE intab INDEX 1.
       t   = intab-value.
    select single RWBTR from reguh into ant where vblnr eq t.
    ant = ant * ( -1 ).
    CALL FUNCTION 'HR_IN_CHG_INR_WRDS'
    EXPORTING
    AMT_IN_NUM               = ant
    IMPORTING
    AMT_IN_WORDS             = words.
    amount = words.
    READ TABLE outtab INDEX 1.
      MOVE WORDS TO outtab-value.
      MODIFY outtab INDEX 1.
    ENDFORM.                    "diff
    with the above code,im getting the amount field in a single line and it goes out beyond the line specified.
    How to split it as a length basis as u said....pls explain in detail...
    thanks & regards
    sankar

  • Taking download into excel from ALV Grid - header is printing in two lines

    Hi All,
    I have a scenario where I am taking the download from ALV grid to an excel sheet. Now the header of the ALV (column names) is appearing in two lines in the downloaded excel sheet while items (records of the ALV table) are getting displayed in a single line.
    This download is taken from the standard download to local file (spreadsheet) button provided by SAP for ALVs.
    I am using function module "Reuse_alv_grid_display" for the purpose.
    Can somebody provide an idea how I can avoid the header printing in two lines and keep the length as it is.
    Thanks in Advance,
    Chandan

    Hi..
    1. Pass header name in internal table appned first line.
    2. after that pass u r data .
    3. Use  FM. WS_DOWNLOAD 
    Salil ......
    Edited by: salil chavan on Nov 26, 2008 11:07 AM

  • Procurement tab in Sales order displays two line items per material

    Folks
    I am not a SD guy and i have a very basic question on how to read the details in the procurement tab for a sals order.
    In the Procurement tab of a Sales order, two line items per material are displayed as shown below. whats does this mean ?
    Further, I had observed the below differences in the below 2 lines
    1. Mat. Avail Date is 06/19/2007 for line 1 & 06/20/2007 in line 2.why r the dates different ?whats the significance?
    2. Confirmed qty is 0 line 1 & 1in line 2.( when does confirmation trigger or update ? Is it upon ATP check or upon delivery ?)
    3. Order qty is 1 line 1 & 0 in line 2.
    Item     Material     Plant     Confirmed Qty     SU     Mat. Avial Date     SL     Req. Type          Deliv. Date     ATP Qty     Loading dt     Route     Part. Deliv/ Item     Deliv priority     Desc                              
    10     NTE801NC     2400     0     EA     6/15/2007     CT          D     6/19/2007     0     6/15/2007     24GB03     C     98     Priority 98 (Normal)                              
                                    1     EA     6/15/2007     CT          D     6/20/2007                   6/15/2007                    Priority 98 (Normal)                              
    Thanks

    It means  2 schedule line for that materials ,
    06/19/2007  is the date on which material is requested by  customer  but there is not sufficient stock on that day so 0 quantity is confirmed for that day.
    On 06/20/2007 material is availabe and you can start delivery to customer on 06/20/2007 and system confirms the material for 20th and it is reserved for this sales order.
    Confirmation is based on your MAT ( Material availability date ), but you can revist these dates through by triggering availabilty check or Back order processing through GATP or ATP.
    Manish

  • How can I get a two-line bookmark toolbar?

    I have too many websites I visit daily! I like having them available at a single click on my bookmarks toolbar, but I'm trying to squeeze too many on there. Is there any way to stretch the toolbar vertically so I can get two lines of bookmarks on there? (Yes, I know, I can put them in the bookmarks dropdown, but that's too many clicks to get to the ones I use every day.)

    *BookmarksToolbars: https://addons.mozilla.org/firefox/addon/46159/
    *Incredible Bookmarks: https://addons.mozilla.org/firefox/addon/50722

  • When i click on an excel or word file in 2007 the program begins to open but then an error message says There was a problem sending the command to the program

    when i click on an excel or word file in 2007 the program begins to open but then an error message says There was a problem sending the command to the program.
    i am using office2007  with windows7 premium home edition.  i have checked file associations., all DDE settings. i have even tried this in safe mode. the same thing happens. please note once i see the error. i can then go back to the file click on
    it a second time and it WILL open. AND i can open any file if i open excel and and find the file from there. i uninstalled and re-installed office 2007 from scratch. And i checked the compatibility mode (all un-checked) still the problem persisits. this is
    a real PITA.   anyone have any solution for this? Thanks 
    ken yanow

    Hi,
    Have you try to un-select the Ignore other applications that use Dynamic Data Exchange (DDE) setting?
    Click the Microsoft Office Button, and then click Excel Options.
    Click Advanced, and then click to clear the Ignore other applications that use Dynamic Data Exchange (DDE)
    check box in the General area.
    Click OK.
    If the problem cannot resolve, the Run as administrator may selected.
    Go to Office default install location: C:\Program Files\Microsoft Office\Office12.
    Right-click EXCEL.EXE > Properties >
    Compatibility tab.
    Under Privilege Level, uncheck Run this program as an administrator
    check box.
    Best regards.
    William Zhou
    TechNet Community Support

  • On Word I was copying a sentence, but the command has not been executed and the timer is constantly circling. It has been circling for over 10 minues. How do I get out of this?

    On Word I was copying a sentence, but the command has not executed and the timing cursor has been circling for over 10 minutes. How do I get out of this?

    You probably will need to force-quit Word. Go to the Apple menu, choose "Force Quit", locate and select Word in the list of applications and click the "Force Quit" button. You will of course most likely lose any changes you made to the document since you last saved it (or it was auto-saved, if you have that option turned on in Word).
    Regards.

  • Simply put, I do not like like the new color coding "dots" and I do not like having to press the Command key before double clicking to open files in a new window. How hard would have been to include the old version of these two features?

    Simply put, I do not like like the new color coding "dots" and I do not like having to press the Command key before double clicking to open files in a new window. How hard would have been to include the old version of these two features?

    Apple - Mac OS X - Feedback

  • What is the command to check the changes in the spanning-tree topology?

    What is the command to check the changes in the spanning-tree topology?

    Hi,
    Few commands which would help are:
    1- Show spanning-tree detail
    2-show spanning-tree detail | in ieee|from|occur|is exec  >> This will give from were the changes occuring- Ex:
    C6K1#show spanning-tree detail | in ieee|from|occur|is exec  
     VLAN0001 is executing the rstp compatible Spanning Tree protocol
      Number of topology changes 9536 last change occurred 00:00:29 ago
              from GigabitEthernet4/6
    3- show spanning-tree active  *& show spanning-tree root >> Will give you the root information.
    4-  show spanning-tree inconsistentports >> If there are any port which are inconsistent state due to STP features.
    STP running MST:
    ===============
    show spanning-tree mst configuration  >> Need to check and match the same outputs with the other switches running in the same MST domain/region.
    show spanning-tree mst detail
    show spanning-tree mst <name of the region>
    Debug on STP:
    ============
    debug spanning-tree events/bpdu >> would be good but to be run with more cautious.
    HTH
    Inayath
    *Plz rate if this info is usefull.

  • ITunes match gave me two identical copies of the instrumental version - want words!

    Imogen Heap's "Ellipse" featured two "CD's" - One featured all her songs sung by her - The other featured all her songs as instrumentals. When syncing with iCloud, iTunes Match gives me access to only the instrumental version of all songs...twice!  So now I only have access to two identical copies of the instrumental tracks - no word tracks - help :-(

    The original versions are still in your iTunes library, so they haven't taken anything away from you.
    It does create problems if you want them on your iOS device though. Unfortunately, I can't give you any idea how to get them on there short of turning match off.
    Sorry, it is a problem at the moment, and you are not alone.

  • Why are there two lines showing when I  switch off my iPad where the cancel word is?

    Why are there two lines showing on my iPad when I turn it off where the cancel word is.

    You wrote:
    "I have noticed that on my IPad Calendar, that on some of the scheduled appointments it is showing Phoenix as a time zone. On some it is showing Salt Lake City, and then on others it will show Denver. I can't quite see why or understand why that this is an issue since everything is set to Salt Lake City. On the ones that show up with Phoenix as the time zone the times change. Also I have had some of the times showing on the calendar at an hour different that when I open the Appointment. It will show the correct time, but on the Calendar it is sometimes different. "
    From that information, it makes sense that your calendar is off.
    Phoenix is in another time zone part of the year.   When daylight saving changed, Salt Lake City and Denver changed, but Phoenix did not.   You may have set time and date to auto, but the Mac knows the time difference and is compensating for it.

  • Why when I press the command button and number two, yahoo comes up instead of the 'at' key? how can I fix the command shortcuts? help me please.

    why when I press the command button and number two, yahoo comes up instead of the ‘at’ key? how can I fix the command shortcuts? help me please.

    try pressing the shift and 2 key to get the @ symbol.
    if that doesn't work for you - go to system preferences - keyboard and change it there.
    good luck

  • I can't order more than one picture at a time in iphoto.  I am holding the command key down and highlighting two but only the last one is showing up

    Hi,
    I need help placing an iphoto order online for prints.  I have a few pictures I want in a few sizes and it seems to only allow me to select one at a time.  I have held the command key down but it defaults to the last picture i selected.  I appreciate your help.

    What system and iPhoto versions are you using?  As a quick test try this:  launch iPhoto with the Option key held down and create a new, test library.  Import some photos and check to see if the same problem persists.  See if you can get all of the selected photos in the order window as it should be.
    If you can't then try this:  make a temporary, backup copy (if you don't already have a backup copy) of the library and try the following:
    1 - delete the iPhoto preference file, com.apple.iPhoto.plist, that resides in your
         User/Home()/Library/ Preferences folder.
    2 - delete iPhoto's cache file, Cache.db, that is located in your
         User/Home()/Library/Caches/com.apple.iPhoto folder. 
    Click to view full size
    3 - launch iPhoto and try again.
    NOTE: If you're moved your library from its default location in your Home/Pictures folder you will have to point iPhoto to its new location when you next open iPhoto by holding down the Option key when launching iPhoto.  You'll also have to reset the iPhoto's various preferences.
    OT

  • How can I open a PDF file and enter a word in the Find field from the command line?

    Hi,
    I want to use a PDF file as the help file of another program.
    I have found somewhere an incomplete description of the command line parameters of Acrobat Reader.
    It described how to open a file and jump to its given page.
    I have written the following batch file based on that.
    rem Open pdf (prm1) with Acrobat reader at given page (prm2)
    "%adobe_rdr%\AcroRd32.exe" /N "zoom=73&page=%2=OpenActions" %1
    The following batch file opens the search dialog:
    rem Open pdf (prm1) with Acrobat reader
    rem and search for something (prm2)
    "%adobe_rdr%\AcroRd32.exe" /N "zoom=73&navpanes=1=OpenActions&search=%2" %1
    I need the simple find field instead of the complicated search window.
    Regards
                   Ferenc

    Not possible.

  • Web-based filters that don't substitute words?(for sites safari can't go 2)

    I haven't been able to get around a problem I addressed in another question, a site where I get an "Invalid IP used" message.
    I have found that I can visit the site using a web-based filter like:
    http://websmurfer.devnull.net/
    There are two drawbacks to that. One is that it is not possible to log into the site that way; nothing can be done about that. The other problem is that that filter makes the site hard to read by substituting (in this case) smurf words for some of the words. That is the purpose of this particular filter, of course.
    Are there other web-based filters that do not substitute words? I still wouldn't be able to log into the site, but at least I would be able to read it without difficulty.
    Thanks!

    I apologize for the delay. I took my macbook to the genius bar, and they fixed the issue by deleting some files from the old OS (though I unfortunately don't know how they did this as a manager in the back room took care of it). I still couldn't visit sites using Java as they said Java had somehow installed incorrectly and I would need to reinstall the OS once again to fix this. I continued to use my machine without trying to fix the Java issue for a few weeks. However, without reinstalling the OS, the exact problem has started again. Yesterday I reinstalled OSX 10.6.3 in order to fix the Java issue, hoping it would fix everything, but Java still isn't working, and I still can't visit certain web sites.
    I have added those two DNS servers, but that did not solve the issue.
    Any advice on how to 1) fix Java and 2) delete the old OS files? I have run all software updates with no luck.

Maybe you are looking for

  • What does this message mean - The operation can't be completed because the item "12b" is in use.

    The operation can't be completed because the item "12b" is in use.  What does this message mean.  It appeared as I was attempting to clear my time machine backup?

  • What does "save" do in MS Office 11 for the mac?

    I'm not sure this is the right forum to ask this in, but here goes: Using MS Office 11 for the mac, if I view mail in my inbox, and click "Save" in the file menu, what does this do? Where is the file saved? "Save As" is grayed out, so this doesn't wo

  • Upgrading from CS4 to CS5 Prod Premium

    Please excuse me if this has been discussed (although I only found one short thread relating to my question). I have received my upgrade version of CS5.5 (DVD version). I am currently running CS4.2.1 Do I have to deactivate my current version before

  • Css layout fix

    I suspect it is imbalanced div tags that is causing the layout issue the following webpage is experiencing. http://www.canchair.com/ While the ph.416.787.1709 etc information is listed to the right of the "quickship!" image, it is really supposed to

  • Error message opening iDVD project

    Need some help figuring this out. I have completed my first DVD project. It is a simple slideshow of a recent trip. I made an image yesterday and it played OK and its 625 MG. I decided to burn it to my LaCie external burner today, but I can't even op