10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have an input file as below
Emp1|FirstName|MiddleName|LastName|Address|Pincode|PhoneNumber
1234|FirstName1|MiddleName2|LastName3| Add1 || ADD2|123|000000000
Output :
1234|FirstName1|MiddleName2|LastName3| Add1 ,, ADD2|123|000000000
OR
1234,FirstName1,MiddleName2,LastName3, Add1 ||... (2 Replies)
Discussion started by: styris
2 Replies
2. Shell Programming and Scripting
Have Pipe Delimited File:
> BRYAN BAKER|4/4/2015|518 VIRGINIA AVE|TEST
> JOE BAXTER|3/30/2015|2233 MockingBird RD|ROW2On 3rd column where the address is located, I want to add a space after every numeric value - basically doing a "s//&\ / ":
> BRYAN BAKER|4/4/2015|5 1 8 VIRGINIA AVE|TEST
> JOE... (5 Replies)
Discussion started by: svn
5 Replies
3. Shell Programming and Scripting
Hi,
I am looking to replacing value of a specific column of /etc/pam.d/system-auth file. My file looks like this
password sufficient pam_unix.so md5 shadow nullok try_first_pass use_authtok
expected result
password sufficient pam_unix.so md5 shadow nullok try_first_pass use_authtok... (5 Replies)
Discussion started by: Litu1988
5 Replies
4. Shell Programming and Scripting
This is a file that I have
test line 1 (55)
)
test line 2 (45)
)
I would like to change all the parens in position 1 of this file to a );
i only want to check position 1 in every line of the file. I have tried different varations of sed, but cannot seem to be able to limit it to... (1 Reply)
Discussion started by: JoeG
1 Replies
5. Shell Programming and Scripting
Input file:
ASD_QAW 12 A_@
AE_AQ 21 PA_123
ASDA_@ 23 ADA_AS
.
.
Output file:
ASD_QAW 12 A @
AE_AQ 21 PA 123
ASDA_@ 23 ADA AS
.
.
Do anybody know how to just specific and replace "_" in column 3 with tab delimiter (\t)?
Thanks for advice. (2 Replies)
Discussion started by: perl_beginner
2 Replies
6. Shell Programming and Scripting
Hi all,
I have two files with the following format:
file1
BBB;33
AAA;2
CCC;5
file2
5;.;.;.
33;.;.;.
The first file contain a list of code and numbers. The second file only the number.
I would like to replace the corresponding code in the first column of the file1 with the... (3 Replies)
Discussion started by: g256
3 Replies
7. Shell Programming and Scripting
Can anyone please help with this? I have 2 files as given below.
If 2nd column of file1 has pattern foo1@a, find the matching 1st column in file2 & replace 2nd column of file1 with file2's value.
file1
abc_1 foo1@a ....
abc_1 soo2@a ...
def_2 soo2@a ....
def_2 foo1@a ........ (7 Replies)
Discussion started by: prashali
7 Replies
8. Shell Programming and Scripting
Input file:
Populus_trichocarpa 30 0 50 0 0 US
Vitis_vinifera 1 18 2 8 6 US
Populus_trichocarpa 1 5 100 0 0 US
Arabidopsis_lyrata_subsp._lyrata 0 90 0 0 0 US
Glycine_max 0 2 3 0 70 UK
Desired output file:
Populus_trichocarpa YES NO YES NO NO US
Vitis_vinifera YES YES YES YES YES US... (4 Replies)
Discussion started by: perl_beginner
4 Replies
9. Shell Programming and Scripting
I have 5 column in sample txt file
where in i have to create report based upon 1,3 and 5 th column..
I have : in first and third coulmn. But I want to retain the colon of fifth coulmn and remove the colon of first column..
5th column contains String message (for example,... (7 Replies)
Discussion started by: Shirisha
7 Replies
10. Shell Programming and Scripting
Hi
My orginal file is like (100s of lines)
id host ip location remarks
1 host1 ip1 - xxx
2 host2 ip2 - xxx
3 host3 ip3 - xxx
--
--
9 host9 ip9 - xxx
I have a ref file like
host1 location1
host2 location2
host3 location3
--
--... (6 Replies)
Discussion started by: ./hari.sh
6 Replies