Search Results

Search: Posts Made By: jagdishrout
992
Posted By jagdishrout
How to replace & with and in tab separated file?
Hi,
I have a tab separated. I want to replace all the "&" in 8th column of the file with "and" .I am trying with
awk -F, -vOFS=\\t '{$8=($8=="&")?"and":$8}1' test> test1.txt

My file is...
650
Posted By jagdishrout
How to append string checking other same string?
Hi ,
I have a file likeA-0044150|ABC/Frito/
A-0044150|GFHU
A-0150075|Bud Racing
A-0187811|Bud Light
A-0187811|RW&B signmaking


I Want the o/p likeA-0044150|ABC/Frito/,GFHU
A-0150075|Bud...
1,736
Posted By jagdishrout
How to make tab delimited file to space delimited?
Hi How to make tab delimited file to space delimited?
in put file:

ABC kgy
jkh ghj
ash kjl
o/p file:

ABC kgy
jkh ghj
ash kjl


Use code tags, thanks.
930
Posted By jagdishrout
Thanks.. Can you please replace the space...
Thanks..

Can you please replace the space with pipe(|) in the o/p file?

BUD,BDL|BUDCAR,BUDLAMP
ABC,CDF,KLT|ABISKAR,CORNEL,KANNAD
JKL,HNM,KTY,KJY|JAGAN,HOUSE,KATAK,KOLKA
930
Posted By jagdishrout
How to append a string by comparing another string?
Hi ,
I have one file like
BUD,BDL BUDCAR
BUD,BDL BUDLAMP
ABC,CDF,KLT ABISKAR
ABC,CDF,KLT CORNEL
ABC,CDF,KLT KANNAD
JKL,HNM,KTY,KJY JAGAN
JKL,HNM,KTY,KJY HOUSE
JKL,HNM,KTY,KJY KATAK...
1,164
Posted By jagdishrout
How to remove space from each record in file?
Hi ,
I want to remove space from each record in one file My file is like
BUD, BDL
ABC, DDD, ABC
ABC, DDD, DDD, KKK

The o/p should be
BUD,BDL
ABC,DDD,ABC
ABC,DDD,DDD,KKK

Can any...
1,986
Posted By jagdishrout
Hi, The code is working fine. But in my...
Hi,
The code is working fine. But in my file each row does not have always 1 comma. It may vary from 1 to many.

its like

BUD,BDL
ABC,XYZ
MNB,JHG,KTR
JKL,KYH,TYP,GHY

the o/p should...
1,986
Posted By jagdishrout
How to split the comma separated file?
Hi,
I have a filein unix like

ABC,CDE
BCD,KHL


and the output i need is like
column1 column2
ABC,CDE ABC
ABC,CDE CDE
BCD,KHL BCD
BCD,KHL KHL. Can some body help me out?


...
Showing results 1 to 8 of 8

 

Featured Tech Videos

All times are GMT -4. The time now is 10:28 PM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy