10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello,
I'm using Bash and Sed to replace text within a text file (1.txt) twice in one script. Using a for loop I'm initially replacing any 'apple' words with the variable 'word1' ("leg). I'm then using another for loop to replace any 'apple' words with the variable 'word2' ("arm"). This task is... (2 Replies)
Discussion started by: Flip-Flop
2 Replies
2. UNIX for Dummies Questions & Answers
Hi,
Please excuse me , i have searched unix forum, i am unable to find what i expect ,
my query is , i have 2 files of same structure and having 1 similar field/column , i need to merge 2 tables/files based on the one matched field/column (that is field 1),
file 1:... (5 Replies)
Discussion started by: karthikram
5 Replies
3. Shell Programming and Scripting
Hi,
I have a requirement in which i need to replace text as below -
<stringProp name="Recipe"><AddGroup Name="1001" Path="ServiceAdministration/Controls/1001/ServiceSwitches">
<Param Name="AttributeName" Value="HeaderManipRspIngressRuleSet" Type="String" />
<Param Name="Value"... (0 Replies)
Discussion started by: abhitanshu
0 Replies
4. Shell Programming and Scripting
Hi All,
I felt tough to frame my question. Any way find my below input. (.CSV file)
SNo, City
1, Chennai
2, None
3, Delhi
4,None
Note that I have many rows ans also other columns beside my City column.
What I need is the below output.
SNo, City
1, Chennai
2, Chennai_new
3, Delhi... (2 Replies)
Discussion started by: ks_reddy
2 Replies
5. UNIX for Dummies Questions & Answers
Hello,
I have a tab-delimited table that may contain 11,12 or 13 columns. Depending on the number of columns, I want to cut and get a sub table as shown below. However, the awk commands in the code seem to be an issue. What should I be doing differently?
#cut columns 1-2,4-5,11 when 12 &... (3 Replies)
Discussion started by: Gussifinknottle
3 Replies
6. UNIX for Dummies Questions & Answers
Hi All,
I am fairly new to the world of Unix, and I am looking for a way to replace a line of text in a file with a delimited array of values.
I have an aliases file that is currently in use on our mail server that we are migrating off of. Until the migration is complete, the server must stay... (8 Replies)
Discussion started by: phoenixjc
8 Replies
7. UNIX and Linux Applications
How would one go about creating 'day' tables based on the timestamp field.
I have some 'import' tables which contains data from various days and would like to spilt that data up into 'days' based on the timestamp field in new tables.
TABLE_IMPORT1
TABLE_IMPORT2
TABLE_IMPORT3
... (2 Replies)
Discussion started by: hazno
2 Replies
8. Shell Programming and Scripting
Hi ,
I have some data in my file(properties.txt) like this.
# agent.properties
agent.dmp.Location=
agent.name=
I need to relpace the
agent.dmp.location with agent.dmp.Location = /opt/VRTS/vxvm
I am using the follwing to replace the string
AGENT_NAME=snmp... (2 Replies)
Discussion started by: raghu.amilineni
2 Replies
9. UNIX for Dummies Questions & Answers
Hi,
Im trying to find and replace text within a unix file using sed.
The command that i have been using is
sed '/,null,/ s//, ,/g' result.txt>result.tmp
for replacing ",null," with ", ,".
But this only replaces the first occurrance of ,null, in every line. I want to do it globally.
It... (7 Replies)
Discussion started by: sohaibs
7 Replies
10. UNIX for Dummies Questions & Answers
I have 2 files that are tab dilimiter:
file1 contains:
T 1 2 3 1000
T 5 10 15 9000
T 4 5 6 2000
T 3 7 9 6000
AND SO ON
file2 contains: (columns number 1, 2, and 3 are match-pattern to file1)
1 2 3 JOHN
4 4 4 MIKE
4 5 6 TOM
3 7 9 MIKE
AND SO ON
I want file3 contains... (3 Replies)
Discussion started by: bobo
3 Replies