New line command help

How can I insert a new line wherever "<" in the following file?
1102,1145d1101 < Mar 2 10:00:03 judas.the-ark.com root: Solstice Backup Savegroup: (info) starting Weekly Backup (with 11 client(s)) < Mar 2 10:00:03 judas.the-ark.com root: Solstice Backup Savegroup: (notice) Weekly Backup completed, 11 client(s) (All Succeeded) < Mar 2 10:00:03 judas.the-ark.com root: Start time: Fri Mar 2 10:00:01 2007 < Mar 2 10:00:03 judas.the-ark.com root: End time: Fri Mar 2 10:00:03 2007 < Mar 2 10:00:03 judas.the-ark.com root: < Mar 2 10:00:03 judas.the-ark.com root: --- Successful Save Sets
I have tried to use this command:
cat /tmp/vam.test | sed 's/</^M/g' but that does not work. Please help...

I can never get that to work - but could awk help?
timu-home ksh: cat foo
fffFF < ffffff < < ffff <
timu-home ksh: awk 'BEGIN{RS="<"}{print}' foo
fffFF
ffffff
ffff
not very elegant but might help
tim

Similar Messages

  • New line command in a string?

    I'm trying to go to a new line in the middle of a string. I was told that the command was /n but that's definitely not working. Can anyone help me out? Thanks

    You were close. It's \n. You can do something like
    System.out.println("this is the first line \nthis is the second line");Or you could do this:
    System.out.println("this is the first line");
             System.out.println("this is the second line");The 'ln' on the end of the print statement starts a new line each time.

  • New line command

    hi
    i was wondering what the command was to make a new line in a string (i.e. a string that runs over multiple lines) , i think it was something like "/n" or something like that, i can't find it anywhere
    any help would be great!
    Thanks
    Sarah

    "\n"Though there is more to it than that! '\n' is the new line character but on some platforms a new line is signified by "\n", otherplatforms use "\r\n" and others just use "\r" . There is a system property String getProperty("line.separator") which defines the new line for the platform you are running on.

  • Cant get it to replace or print to new line, please help

    2 problems. The instructions are to first replace each 's' with '$' and then print each word to a new line. Here is an example:
    Give me a phrase: Viva Las Vegas, babies!
    Viva
    La$
    Vega$,
    babie$.
    Here is my code that is not working:
    import java.util.*;
    public class StringEdit {
         private static Scanner input ;
         private static String makeMoney[] ;
         public static void main(String[] args)throws Exception {
              System.out.print ("Give me a phrase: ") ;
              input = new Scanner (System.in) ;
              makeMoney = input.nextLine().split(" ") ;
              //makeMoney = makeMoney.replace("s", "$") ;
              int i = 0;
              while (i < makeMoney.length) ;{
              if (makeMoney.contains("s")){
                   System.out.println("Show me here");
                   makeMoney[i].replace("s", "$");
              if (makeMoney[i].contains("S")){
                   System.out.println("Show 2");
                   makeMoney[i].replace("S", "$");
              System.out.print(makeMoney[i].toString());
              i++ ;
    Please help me figure out what is wrong

    your first post was the one which you really wanted to use for the assignment in order to get the output you desire. anyways like jverd said that you cannot update string because they are immutable. you can always do this
    makeMoney[i] = makeMoney.replace(blah blah).
    here is your program
    import java.util.*;
    public class StringEdit {
         private static Scanner input ;
         private static String makeMoney[] ;
         public static void main(String[] args)throws Exception {
              System.out.print ("Give me a phrase: ") ;
              input = new Scanner (System.in) ;
              makeMoney = input.nextLine().split(" ") ;
              //makeMoney = makeMoney.replace("s", "$") ;
              int i = 0;
              while (i < makeMoney.length) {
              if (makeMoney.contains("s")){
                   System.out.println("");
              makeMoney[i] =     makeMoney[i].replace("s", "$");
              if (makeMoney[i].contains("S")){
                   System.out.println("");
              makeMoney[i] =      makeMoney[i].replace("S", "$");
              System.out.print(makeMoney[i].toString());
              i++ ;
    output
    Give me a phrase: Viva Las Vegas
    Viva
    La$
    Vega$Message was edited by:
    fastmike

  • At new line command

    Hi,
    I have a string like below...
    abcdef,12345,ghvbth,kjuytg
    and i want it to appear like this
    abcdef,
    12345,
    ghvbth,
    kjuytg
    Any syntax help to get this..
    Regards
    Praneeth

    Hi praneeth,
    1. Simple
    2. we have to use SPLIT
    3. just copy paste in new program.
    4. it will output
    abcdef  
    12345   
    ghvbth  
    kjuytg  
    5.
    report abc.
    data : mystr(100) type c.
    data : begin of itab occurs 0,
           str(25) type c,
           end of itab.
    mystr =  'abcdef,12345,ghvbth,kjuytg'.
    split mystr at ',' into table itab.
    loop at itab.
    write :/ itab-str.
    endloop.
    6.*----
    If u want the COMMA also,
    then use like this (just copy paste)
    7.
    report abc.
    data : mystr(100) type c.
    data : begin of itab occurs 0,
           str(25) type c,
           end of itab.
    mystr =  'abcdef,12345,ghvbth,kjuytg'.
    replace all occurrences of ',' in mystr with ',@'.
    split mystr at '@' into table itab.
    loop at itab.
    write :/ itab-str.
    endloop.
    regards,
    amit m.

  • Format bold text in field and putting some text on new line - Help!

    I am lost.  I found the rich text formating item to click.  But after that, I don't know what to do next.  I want to bold some characters and I want some reponses on separate lines as I asked previously.  As to spans and the commands - I have no programming experience.  I have just been using what George has given me.  It has worked well, but I just need the bold text in some of the field text to be printed and I need some items to be on separate lines.  But I have no idea where to put the information you are saying about spans and I do not know the script to use to bold text or to start text on new line.  Am I to insert it in the calculation box of the text box?  Sorry to be so lame, but I am void in programming skills.  Help!
    For example, here is the script.  In aISOreq{0], if I want to bold "Patter#1 Check:", where do I put the span and what script do I use to say to bold it.   Could you give me an example, please.  Also, if I want to put "a. Medications on weekend?" on one line and "b. Activities on weekends? Types of activities? Supervision? With who?" on the next line, where do I put the span and what script do I use to say to put on separate lines?  Could you give me an example for this also, please.  I have literally just used the scripts George has given me and they work great - but that is all I know how to do.  Thanks.
    (function () {
        // Set up an array to hold the individual paragraphs of text
        var aISOfreq= [];
        // Populate the array with paragraph text
       aISOfreq[0] = "Pattern #1: Multiple Isolations on Mon & Tues decreasing to Fri.  Pattern # 1 Check: a. Medications on weekend?  b. Activities on weekend? Types of activities? Supervision? With who?";
       aISOfreq[1] = "Pattern #2: Multiple Isolations on specific days.  Note days.  Pattern #2 Check:  a.  Different schedule on these days? Different adult? Block schedule? May need consistent schedule w/same adult.  b.  Are accommodations/modifications occurring? More group v. individual instruction? Does the student need warm-up drills or a specific job?  Does student need a specific lesson routine? c.  Previous night's activities?  Need calming activities before bed?  Need earlier bedtime? Need additional evening structure?";
       aISOfreq[2] = "Pattern #3: Isolations are grouped in intervals.  Note interval.  Pattern #3 Check:  a.  Cyclic behavior?  Review assessment.  Need Mental Health referral for meds and/or therapy intervention?  b.  Medication: supervision? Self-medicating? Taking consistently? Need medication check with physician?  Share concerns with physician?  c.  History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns with PO?";
      aISOfreq[3] = "Patterns #1 & #2: Multiple Isolations on Mondays & Tuesdays decreasing to Fridays AND Multiple Isolations on specific days.  Note days.  Pattern #1 Check:  a. Medications on weekend?  b. Activities on weekend? Types of activities? Supervision? With whom?  Pattern #2 Check:  a. Different schedule on specific days? Different Adult? Block schedule? May need consistent schedule with same adult.  b. Accommodations/modifications occurring? More group v. individual instruction? Need warm-up drills or specific job?  Need a specific lesson routine?  c. Previous night's activities? Need calming activities before bed? Need earlier bedtime? Need additional evening structure? ";
       aISOfreq[4] = "Patterns #1 & #3: Multiple Isolations on Mondays & Tuesdays decreasing to Fridays AND Isolations grouped in intervals.  Note intervals.  Pattern #1 Check:  a. Medications on weekend?  b. Activities on weekend? Types of activities?  Supervision? With whom?   Pattern #3 Check:  a. Cyclic behavior?  Review assessment.  Need Mental Health referral for meds and/or therapy intervention?  b.  Medication supervision? Self-medicating? Taking consistently? Need med check with physician?  Share concerns with physician?  c.  History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns w/PO?"
      aISOfreq[5] = "Patterns #2 & #3: Multiple Isolations on a specific day AND Isolations grouped in intervals.  Note days & intervals.  Pattern #2 Check:  a.  Different schedule? Different Adult? Block schedule? May need consistent schedule w/same adult.  b.  Accommodations/Modifications occurring? More group v. individual instruction? Need warm-up drills or a specific job?  Need a specific lesson routine? c.  Previous night's activities?  Need calming activities before bed?  Need earlier bedtime? Need additional evening structure?  Pattern #3 Check:  a. Cyclic behavior? Review assessment.  Need Mental Health referral for medication and/or therapy intervention?  b.  Medication supervision? Self-medicating? Taking consistently? Need medication check with physician?  Share concerns with physician?  c. History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns w/PO?";
       aISOfreq[6] = "Patterns #1, #2 & #3: Multiple Isolations on Mondays & Tuesdays decreasing to Friday, Multiple Isolations on specific days AND Isolations grouped in intervals.  Note days and intervals.  Pattern #1 Check: a. Medications on weekend?  b. Activities on weekend? Types of activities? Supervision? With whom?   Pattern #2 Check:  a. Different schedule? Adult?  Block schedule?  May need consistent schedule w/same adult.  b.  Accommodations/Modifications occurring? More group v. individual instruction? Need warm-up drills or a specific job?  Need a specific lesson routine? c.  Previous night's activities?  Need calming activities before bed?  Need earlier bedtime? Need additional evening structure?  Pattern #3 Check:  a. Cyclic behavior? Review assessment.  Need Mental Health referral for medication and/or therapy intervention?  b.  Medication supervision? Self-medicating? Taking consistently? Need medication check with physician?  Share concerns with physician?  h.  History of legal/illegal drug abuse?  Share cyclic pattern with physician.  On probation?  Share concerns w/PO?";
       aISOfreq[7] = "No Pattern";
         // Get the selected item, which is the export value of the selected combo box item
        var item = getField("ISO Frequency Pattern").value;
        // Display the text corresponding to the selected item in the text field
        event.value = aISOfreq[item];

    Look at the reference of the richValue property of the Field object. It contains a couple of examples of how it should be done. Also read the reference of the Span object.

  • Pressing Enter inserts new line break instead of "executing" command

    I have noticed a rather strange behavior on my new TPT2. This occurs ONLY when I am using the Windows 8 touch keyboard in the "Metro" environment.
    Whenever I press the Enter key on said keyboard (for example when sending an instant message on Skype), the keyboard inserts a new line in the text box instead of acting like a "normal" Enter key and execute the default command (send the message in this example).
    I have connected an external keyboard and this problem does not show up. Everything works as expected. I also brought up the regular on-screen keyboard (launched from the Ease of Access menu) and it works the way it should. The problem is only with the Metro touch keyboard.
    It seems that for some reason, the Metro touch keyboard interprets the Enter key pressing as "insert a line break".
    Does anyone know how to fix this? It is extremely annoying.

    Just checked that, you are right, Photoshop doesn't recognize Shift-Enter as a line break and treat it as a Return which is a problem with paragraph formatting. Obviously a bug.
    Good news workaround is that it recognizes the line break character if you paste it from another program like Microsoft Word. If you don't have a program that allows you to copy just that character and use paste instead of Shift-Return, you have to type your entire text in some other program and copy paste to Photoshop.

  • New/Additional phone line question- help please!

    Hi
    I am after some advice, and every time I call BT I get passed around as I am not 100% on what to ask for, or who I should speak to.
    Basically, we have 2 phone lines coming into the house.  One line/number + broadband signal goes via a repeater to the office which is a separate building across the garden (approx 300m but I am not sure on the actual distance).  The signal is not great, for the broadband particularly - often drops out etc.  To solve this we would like a new physical line installed in the office building to give us a separate phone and broadband package to that of the main house, but ideally keeping the same number as we currently use in the office.  The office is used everyday for working from home and so is important to us.
    Does that make sense?  I fully expect that an engineer will need to look at the site, and there will be a (significant) charge for the line to be installed (underground pipe work for cables already exists from house to office building and so this could be utilised).  Do I just place an order for a new line online, and wait for an engineer's visit?  Can I deal with changing the number at a later date if that is easier for the system to deal with?  Last time I rang BT, I was told I needed to speak to the exceptions team, when I was put through to them she told me all I needed to do was speak to customer services, customer services thought I was trying to move home and then didn't seem to understand what I needed (but it was probably how I was explaining it!).
    I would be so grateful if someone could point me in the right direction, or give me tips on what to ask for.  My main worry is keeping the same phone number as it would be so much easier.
    Thanks in advance
    MPA

    this link may help http://www.openreach.co.uk/orpg/home/network/whoar​eyou/selfbuild/selfbuild.do
    If you want to say thanks for a helpful answer,please click on the Ratings star on the left-hand side If the reply answers your question then please mark as ’Mark as Accepted Solution’

  • Siri command "new line" in Siri not working while texting directly in Siri?

    Hi,
    Seems that "new line" and "paragraph" don´t work in the Siri GUI - at least the German pendants "Neue Zeile" and "Neuer Absatz" don´t work on my 4S.
    It works fine in apps like mail but not when creating a mail directly dictaed to Siri..
    Thx
    Sebastian

    I am able to get "new line" to work consistently in NOTES. However, it took a while for SIRI to learn what I wanted. At first, SIRI would type out the command. Then I would enter return from the keypad. After about 6 cycles, she learned it and started skipping ta a  new line. I'm not sure what I am going to do when I want to actually type "new line" !  There should be a hot word to use to let SIRI know to interpret the next word as a command suggestion. But I solved my new linds issue.

  • Help! When I set Colunm_header_visible=off(web item), I can't see new line

    Please help!
    When I set COLUMN_HEADER_VISIBLE = OFF for Web Analysis item I can't see new line for input ready form. What should I do to fix this problem?
    Thank you
    Edited by: AlexNK on Jul 9, 2009 10:01 AM

    Please help!
    When I set COLUMN_HEADER_VISIBLE = OFF for Web Analysis item I can't see new line for input ready form. What should I do to fix this problem?
    Thank you
    Edited by: AlexNK on Jul 9, 2009 10:01 AM

  • Please help to add new line at Header layout FBL3N

    Dear Expert,
    I need a requirement to custom the program from tcode FBL3N. So i copied the program become my custom program.
    At the custom program, I need to add a new line for display total balance GL account for the previous month at header layout, under text company code.
    For the Information, FBL3N used ALV List to display layout.
    Is it possible to add new line??
    If it's possible, how is the way to add that new line to display the total GL account?
    I really appreciate your suggestion and solution.
    Thank you,

    Thanks for all your help. My problem was that I was using 2 lists to update the table. The problem solve!!!!
    int modelIndex = listWhenScrollStop.size () - 1 - aRow;
    if (modelIndex >= 0) {
    return listWhenScrollStop.get (listWhenScrollStop.size () - 1 - aRow);

  • New line in smartforms after the enter command .

    Hello experts ,
    I get text from a text box , and i need to display it in table field on my form.
    After the user push the 'ENTER' button during inserting the text , i need to display this text in a new line
    How can i  do this ?
    Thanks for your help.
    AVI.

    Hello Sakkthiss.R ,
    For example , the user write the following text :
    Hello world
    today is
    a nice
    day
    After every line in this text the user push the enter button, in the table filed which will be display in the form, the text should be display as it is written below.
    I hope it is clear now.
    Thanks for your help,
    Avi.

  • Design Help! Add new lines

    Hi All,
    I need a design help for adding extra lines on an existing order.
    I have a page with 2 subtabs, first one is for order header info inputs and second one is for line info inputs. The line subtab base on user selection may generate mutile lines in lineVO (multiple rows). After user clicked an apply button on line subtab, a header row will be committed into header table and line row(s) will be in line table.
    I was trying to have another button to allow user enter extra lines after committed existing header and line VO. After user click the "add extra line" button, I retain AM to keep header VO but flush out line VO, with this way, framework will try to delete lines in line table.
    Since there are lots logic requirements, I can't keep adding lines after line VO.last() without committing first round line entering.
    How can I keep Header VO, clean line VO, then enter new line(s) info as ADD but not DELETE/UPDATE? any suggestion??
    Thanks & Regards,
    KJ

    Hi Shreya,
    I am not sure about giving new line in each and every page, but there is an alternate. You can show all data in one single page. That is how much ever records you have, they will be shown on one single page, instead of spanning across multiple pages. You can achieve this by changing the property "Number of Data rows displayed at once" from default 100 to 0.
    Hope it helps.
    Regards,
    Arunan.C

  • New line character and carriage return in XML, please help, thanks

    In XML, "&#10;" is only the new line character. I have tried that. If you put that in your XML, for example:
    <tag>line1&#10;line2&#10;line3</tag>
    You will get the output as follow:
    line1
    ____line2
    ________line3
    (where ___ represents space)
    The output that I want is actually like:
    line1
    line2
    line3
    So I would like to ask how I can do this.
    Thanks,
    Jackie

    while parsing your XML file you can directly suppress these newline and similar things in characters() method of SAX parser.
    you can opt to do nothing when you encounter them else if it is normal character then use it to print it.

  • Need help in how to print new line character in unix using java

    Hi All,
    I use the printstream class to print some line in a text using java.
    here is the code:
       FileOutputStream out; // declare a file output object
            PrintStream p; // declare a print stream object
                    p.print("\t");
                    p.print(date);
                    p.print("\t\t");
                    p.print(RecCount);
                    p.println("\n");when i use this and output of this character in windows is
    date RecCount
    22-07-2007 23456
    when i use the same code in unix it shows the following output:
    date RecCount[]22-07-2007
    it wont accept the new line character could any one give me an idea to solve this problem.

    PrintStream has a println() method. Use that. Or System.getProperty("line.separator").
    Because a newline char doesn't necessarily specify a line break. It's system-dependent.

Maybe you are looking for

  • Can I connect old Time Capsule to new iMac with Ethernet?

    I recently purchased a new iMac, and I am trying to use a 2008 Time Capsule for back-up.  I successfully used the Time Capsule for back-up with a MacBook for the last four years, but the iMac's Time Machine won't recognize the Time Capsule as a back-

  • Assign a transaction code to a Quickview in SE93

    Hi, I created a quickview using t-code SQVI. I want to assign this quickview to a transaction code using t-code SE93. In SE93, I maintained: Name of screen field: D_SREPOVARI-REPORTTYPE   Value: AQ Name of screen field: D_SREPOVARI-REPORT  Value: ???

  • Scsi to Firewire adapter

    I want to use my old microteck scanner with my iMac but since my scanner uses a scsi, I would need an adpapter. Couple of questions: 1. Should I get a scsi to Firewire or scsi to USB? Which is faster (I'm guessing firewire but not sure) 2. Where can

  • Where did the 'Sleep Timer' setting go?

    I know this seems like a bit of a silly question, BUT: I frequently fall asleep listening to my iPod. I've had 3 other iPods (1st and 2nd gen) which had sleep timers built in as a function on the menu. I could hook the ipod up to speakers in my bedro

  • How to patch SAP J2EE instance ?

    Hello, We are at patch level 8 on SAP J2E instance and would like to apply Patch 12. What is the procedure to patch SAP J2EE ? Thanks