?
Solved

Removal of ^M at end of record...

Posted on 2003-03-10
2
Medium Priority
?
373 Views
Last Modified: 2013-12-26
I have AIX on my servers and dos2unix is not available on AIX.  How do I get rid of ^M at the end of a record?  I also tried :%s/^M/ and it tells me: ex: 0602-007 The pattern does not exist.
What can I use to get rid of the ^M if the client doesn't know to send me the file in ASCII format?
             
EX:  "01-Mar-2002","1667","234","IN","744","744","1",,"0.995","-0.005",,"ALL","13-Sta
te"^M

thanks,
JGreenwood
0
Comment
Question by:JGreenwood
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 21

Accepted Solution

by:
tfewster earned 200 total points
ID: 8104727
^M is a single character - reproduce it by pressing Control-V then Control-M in your command

e.g. sed s/^M// file > newfile
0
 

Author Comment

by:JGreenwood
ID: 8105219
that worked, thanks!!!
0

Featured Post

Will your db performance match your db growth?

In Percona’s white paper “Performance at Scale: Keeping Your Database on Its Toes,” we take a high-level approach to what you need to think about when planning for database scalability.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question