home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / os / msdos / misc / 6171 < prev    next >
Encoding:
Internet Message Format  |  1992-11-17  |  2.5 KB

  1. Path: sparky!uunet!oracle!unrepliable!bounce
  2. Newsgroups: comp.os.msdos.misc
  3. From: skanga@us.oracle.com (Shiraz Kanga)
  4. Subject: Re: Echo command in batch files
  5. Message-ID: <1992Nov16.204439.17539@oracle.us.oracle.com>
  6. Sender: usenet@oracle.us.oracle.com (Oracle News Poster)
  7. Nntp-Posting-Host: wrpyr4.us.oracle.com
  8. Organization: Oracle Corporation, Redwood Shores CA 94065
  9. References: <1992Nov14.190918.9554@oracle.us.oracle.com>
  10. Date: Mon, 16 Nov 1992 20:44:39 GMT
  11. X-Disclaimer: This message was written by an unauthenticated user
  12.               at Oracle Corporation.  The opinions expressed are those
  13.               of the user and not necessarily those of Oracle.
  14. Lines: 56
  15.  
  16.  
  17. In article <1992Nov14.190918.9554@oracle.us.oracle.com> skanga@us.oracle.com (Shiraz Kanga) writes:
  18. >Hi folks
  19. >
  20. >Does anyone know how to prevent echo from issuing a CR/LF at the end of a line.
  21. >
  22. >Eg : If I create the following file called test.bat
  23. >
  24. >echo hello > temp
  25. >echo world >> temp
  26. >
  27. >The result in temp is:
  28. >hello 
  29. >world
  30. >
  31. >I need the result to be:
  32. >hello world
  33. >
  34. >And yes I know echo hello world will work but what I'm trying to do is
  35. >concatenate two strings which are output by two different programs and
  36. >get both onto one line.
  37. >
  38. >Please respond by mail and I'll summarize to the net if there's interest.
  39. >
  40. >thanks
  41. >
  42. >shiraz
  43. >skanga@oracle.com
  44. >-- 
  45. >Shiraz Kanga (skanga@oracle.com) Tel: (415)506-5412 Fax: (415)506-7822
  46. >Analyst -- Desktop Tools Group -- Worldwide Technical Support -- 3OP11
  47. >Oracle Corporation 500 Oracle Pkwy, MS 659311, Redwood Shores CA 94065
  48. >"I work for Oracle - I speak and type (over here at least) for myself"
  49.  
  50. Well folks, as promised heres my summary (since there was little interest)
  51.  
  52. Some people suggested using external echo commands (xecho, etc) which are
  53. available for anonymous ftp from various sites. This is not useful for me
  54. since I am not using echo only.
  55.  
  56. Another person suggested trying an embedded backspace which might erase the
  57. CR/LF characters in the file. I did try this before posting and could not get
  58. it to work.
  59.  
  60. The most useful suggestion was to concatenate the strings in the dos environment
  61. and then output the variable to a text file. I will try this (albeit clumsy)
  62. method as soon as I have the time.
  63.  
  64. Thanks for the replies
  65.  
  66. Shiraz
  67. -- 
  68. Shiraz Kanga (skanga@oracle.com) Tel: (415)506-5412 Fax: (415)506-7822
  69. Analyst -- Desktop Tools Group -- Worldwide Technical Support -- 3OP11
  70. Oracle Corporation 500 Oracle Pkwy, MS 659311, Redwood Shores CA 94065
  71. "I work for Oracle - I speak and type (over here at least) for myself"
  72.