Adding new line character


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Adding new line character
# 8  
Old 05-24-2012
Code:
d2d75796-3643-4ff7-907d-364da0cb265f|20090508911|0|0|0|1000003907519
|20090509316|0|0|0|1000015538346| |Sierra|J|Castedo Rodgers
657eb9dc-536c-4528-b7dd-460ef8cf7c46|20090603702|250|0|0|1000014950343
402ad435-7cd4-4e45-b779-decb0de42db6|20090603982|250|0|0|1000000009808
|20090604343|250|0|0|1000015548013| |Alton| |Anderson| |273 krystle
60afc667-ce71-4543-adcd-2c4224fb51a9|20090604354|250|0|0|1000006312304
240dc881-b7b3-4486-b0c1-aa51344fb3dd|20090902893|0|0|0|1000004791203| 
|20090902926|0|0|0|1000008004140| |Karen| |Johnston| |75 Laxalt Dr| |
289b6a7f-ff77-4964-b447-83c759a83028|20091203344|0|0|0|1000015599379|
END OF FILE. ROW COUNT: 1326542

# 9  
Old 05-24-2012
Are you sure this format is correct and nothing wrong with the file?
Again, Did you took it from a non-unix system (windows)?
check and post the o/p of the below command

Code:
tail file | sed l

# 10  
Old 05-24-2012
Check now...

Code:
d2d75796-3643-4ff7-907d-364da0cb265f|20090508911|0|0|0|1000003907519| |\
Evelyn| |Valdez| |2802 Jadewood Ct| |||Austin|TX|78748-5360|20120511|N
d2d75796-3643-4ff7-907d-364da0cb265f|20090508911|0|0|0|1000003907519| |Evelyn| |Valdez| |2802 Jadewood Ct| |||Austin|TX|78748-5360|20120511|N
|20090509316|0|0|0|1000015538346| |Sierra|J|Castedo Rodgers| |210 W 38T\
h St|# 10|||Austin|TX|78705-1445|20120511|Y
|20090509316|0|0|0|1000015538346| |Sierra|J|Castedo Rodgers| |210 W 38Th St|# 10|||Austin|TX|78705-1445|20120511|Y
657eb9dc-536c-4528-b7dd-460ef8cf7c46|20090603702|250|0|0|1000014950343|\
 |Meranda|ann|Simmons| |6804 Pierce St| |||Norfolk|VA|23513-3028|201205\
11|N
657eb9dc-536c-4528-b7dd-460ef8cf7c46|20090603702|250|0|0|1000014950343| |Meranda|ann|Simmons| |6804 Pierce St| |||Norfolk|VA|23513-3028|20120511|N
402ad435-7cd4-4e45-b779-decb0de42db6|20090603982|250|0|0|1000000009808|\
 |Kenneth|John|Obrien| |5372 El Dorado Dr| |||Huntington Beach|CA|92649\
-4566|20120511|N
402ad435-7cd4-4e45-b779-decb0de42db6|20090603982|250|0|0|1000000009808| |Kenneth|John|Obrien| |5372 El Dorado Dr| |||Huntington Beach|CA|92649-4566|20120511|N
|20090604343|250|0|0|1000015548013| |Alton| |Anderson| |273 krystle loo\
p| |||sagle|ID|83860|20120511|Y
|20090604343|250|0|0|1000015548013| |Alton| |Anderson| |273 krystle loop| |||sagle|ID|83860|20120511|Y
60afc667-ce71-4543-adcd-2c4224fb51a9|20090604354|250|0|0|1000006312304|\
 |Lisa| |Blake| |809 Mallard Creek Ct| |||Roseville|CA|95747-4653|20120\
511|N
60afc667-ce71-4543-adcd-2c4224fb51a9|20090604354|250|0|0|1000006312304| |Lisa| |Blake| |809 Mallard Creek Ct| |||Roseville|CA|95747-4653|20120511|N
240dc881-b7b3-4486-b0c1-aa51344fb3dd|20090902893|0|0|0|1000004791203| |\
Doniel| |Henderson| |3024 Ambarwent Rd| |||Reynoldsburg|OH|43068-8223|2\
0120511|N
240dc881-b7b3-4486-b0c1-aa51344fb3dd|20090902893|0|0|0|1000004791203| |Doniel| |Henderson| |3024 Ambarwent Rd| |||Reynoldsburg|OH|43068-8223|20120511|N
|20090902926|0|0|0|1000008004140| |Karen| |Johnston| |75 Laxalt Dr| |||\
Carson City|NV|89706-7763|20120511|Y
|20090902926|0|0|0|1000008004140| |Karen| |Johnston| |75 Laxalt Dr| |||Carson City|NV|89706-7763|20120511|Y
289b6a7f-ff77-4964-b447-83c759a83028|20091203344|0|0|0|1000015599379| |\
Maria| |Vishnevskiy| |121 Granite Hill Ct| |Pmb|10|Langhorne|PA|19047-1\
017|20120511|N
289b6a7f-ff77-4964-b447-83c759a83028|20091203344|0|0|0|1000015599379| |Maria| |Vishnevskiy| |121 Granite Hill Ct| |Pmb|10|Langhorne|PA|19047-1017|20120511|N
END OF FILE. ROW COUNT: 1326542
END OF FILE. ROW COUNT: 1326542

Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Read character by character in line in which space is also included

Hi friend, I have one file , and i want to read that file character by character. I need this script in ksh. while using read option with -n1 am getting error. while read -n1 c read has bad option And if i am using below script, then if in a line has space like this ( Pallvi mahajan)... (10 Replies)
Discussion started by: pallvi_mahajan
10 Replies

2. Shell Programming and Scripting

Adding a character

Hello experts. I trying to achieve 2 things here. I'm trying to convert all of the host names to lower case and add an "m" to each hostname. Can anyone provide some guidance on what I can do? Your input is greatly valued! Here are the desired results: 1. read the host name from a file. 2.... (8 Replies)
Discussion started by: david_tech
8 Replies

3. Shell Programming and Scripting

Adding end of line character in the last record

Need to add end of line character to last record in a fixed width file. When i take the record length of each line, for all the records it gives example like 200 except the last line as 199. Due to this my other script fails. Please help me on this. (4 Replies)
Discussion started by: Amrutha24
4 Replies

4. HP-UX

How to remove new line character and append new line character in a file?

Hi Experts, I have data coming in 4 columns and there are new line characters \n in between the data. I need to remove the new line characters in the middle of the row and keep the \n character at the end of the line. File is comma (,) seperated. Eg: ID,Client ,SNo,Rank 37,Airtel \n... (8 Replies)
Discussion started by: sasikari
8 Replies

5. Shell Programming and Scripting

Fill the empty line by adding line before blank line

FIle A "A" 2 aa 34 3 ac 5 cd "B" 3 hu 67 4 fg 5 gy output shud be A"" 2 aa 34 "A" 3 ac 34 "A" 5 cd 34 "B" 3 hu 67 "B" 4 fg 67 "B" 5 gy 67 (6 Replies)
Discussion started by: cdfd123
6 Replies

6. UNIX for Dummies Questions & Answers

Adding a character

Hi, I cant seem to figure out how I add a character to an existing one. Heres my problem. So I have a line that looks like this: >56 584848392394958586858484849393 What I want to do is add Num in front of the 56. So basically I want to recognize the > and add Num in front of the... (6 Replies)
Discussion started by: kylle345
6 Replies

7. Shell Programming and Scripting

Adding a special character at the end of the line

I used following to add * at the end of the line in file1. It adds * at the end but has a space before it for some lines but some other lines it adds exactly after the last character. How do I take out the space ? sed 's/$/*/' file1 > file2 example: contents of file1 : ... (2 Replies)
Discussion started by: pitagi
2 Replies

8. Shell Programming and Scripting

adding a character in front of a line

Hi everyon, I am trying to search for a pattern in a file and add "//" to the begining of the file. lets say i want to comment out a line from my codes. the line that should be commented out contains the word "reset". i need to search for the word "reset" and comment out that specific line. is... (5 Replies)
Discussion started by: ROOZ
5 Replies

9. Shell Programming and Scripting

Adding CTRL-M Character

Hi, I have file generated in HP-UNIX environment (for Example) with the line feed (i.e $): a$ b$ C$ Now, I need to append CTRL-M character at the end of each line, but the last line of the file should not have both CTRL-M and Line Feed (i.e ^M and $). The file should look like: a^M$ b^M$... (2 Replies)
Discussion started by: mohan.nadaraja
2 Replies

10. Shell Programming and Scripting

Adding a character in the beginning of every line in a .dat file

How can i add a character(#) in the beginning of every line in a .dat file (2 Replies)
Discussion started by: Cool Coder
2 Replies
Login or Register to Ask a Question