10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have a requirement as below.
In one of my column, I have data which may or may not be separted with coma always. Now I need to validate the length of these text within the coma (if available) and if the length is more than 30 characters, I need to insert a coma either at 30 characters if its... (3 Replies)
Discussion started by: aramacha
3 Replies
2. Shell Programming and Scripting
Hi. I'm a complete noob when it comes to scripting. I have approximately 2000 files scattered throughout different locations that I need to rename. The current files have a character, "." , that needs to be replaced with an underscore. I have no clue which route to go about correcting this.... (4 Replies)
Discussion started by: Nvizn
4 Replies
3. Shell Programming and Scripting
I'm coding using BASH and have a requirement to replace apostrophes with backslash apostrophes. For example below:
I am here 'in my room' ok
Would be changed to:
I am here /'in my room/' ok
The original text is coming from a field in a MySql database and is being used by another process that... (5 Replies)
Discussion started by: dbjock
5 Replies
4. Shell Programming and Scripting
Hi all,
Greetings,
I have the following scenario, The contents of main file are like :
Unix|||||forum|||||||||||||||is||||||the||best
so||||||be|||||on||||||||||||||||||||||||||||||||||||||||||||it
And i need the output in the following form:
Unix=forum=is=the=best
so=be=on=it
... (3 Replies)
Discussion started by: dipanchandra
3 Replies
5. Shell Programming and Scripting
Hi All,
Was wondering how I can do the following....
I have a String as follows
"ACCTRL000005022RRWDKKEEDKDD...."
This string can be in a file called tail.out or in a Variable called $VAR2
Now I have another variable called $VAR1="000004785" (9 bytes long), I need the content of... (5 Replies)
Discussion started by: mohullah
5 Replies
6. Shell Programming and Scripting
Hi,
i have log like this :
Actually i want to change the time stamp, and the rule is like this :
and My script is like this :
I know the script will loop and loop again after 07:00
like this:
Can somebody help me ??
Thanks in advance.. (5 Replies)
Discussion started by: justbow
5 Replies
7. Shell Programming and Scripting
Can someone help me to write a script / command to read in a file, character by character, replace any unknown ASCII characters with space. then write out the file to a new filename/
Thanks! (1 Reply)
Discussion started by: raghav525
1 Replies
8. UNIX for Dummies Questions & Answers
I'm goin to drive crazy soon, if i can not do this. I have a text file (570kb) and i have to replace the apostrophe " ' " and minus "-" with space " ". i have done it for minus:
sed 's/-/ /g' aaa.txt >zzz.txt
this replaced minus with space.
but i can not use the same command for ' .
... (4 Replies)
Discussion started by: onculo
4 Replies
9. UNIX for Dummies Questions & Answers
Hi all
i am very new to shell scripting,hope u guys can help
i need to replace,sort and append character for the file that look like this:
1007032811010001000100000001X700026930409
1007032811010001000200000002X700026930409
1007032711020001000300000003X700026930409... (2 Replies)
Discussion started by: ashikin_8119
2 Replies
10. Shell Programming and Scripting
Hi,
I am using the KSH shell. I am facing a problem of escaping apostrophe('), that is occuring in a variable.
I used the following command, but in vain
item=`echo $item|sed 's/'/\'/g'`
this code replaces the occurance of ' in an xml file to apostrophe(') symbol.
The output of... (2 Replies)
Discussion started by: mradul_kaushik
2 Replies