10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
So basically I have this file containing query output in seperated columns.
In particular column I have the below strings:
news
news-prio
I am trying to grep the string news without listing news-prio aswell.
I tried
grep "$MSG_TYPE" ,
grep -w "$MSG_TYPE" ,
grep... (4 Replies)
Discussion started by: nms
4 Replies
2. Shell Programming and Scripting
Hello All,
I have to write a shell logic inside my ANT Script , the data from my ANT is in the string like
string a = "test1.props,test2.props,*,test3.props,?,test4,props"
how do i remove this wild card characters from my string a and assign them to an other string , like i only want to... (9 Replies)
Discussion started by: raokl
9 Replies
3. Shell Programming and Scripting
Hello All
I have a file like this
abc.tpt.ctl
bdc.tpt.ctl
cdw.tpt.ctl
I have looped every line using the for Loop, now I want to take each line and cut the .tpt.ctl part of it and store it in a variable and use the variable in same loop.
The part I am stuck at is how do I cut the last... (9 Replies)
Discussion started by: nnani
9 Replies
4. Shell Programming and Scripting
Hi all.. I have several unique files that contain one thing in common, and that is acct#. For all files in the directory, I want to append the 10 characters following the word "ACCOUNT:" to the end of the filename.
for example:
I have file 111_123 that contains ACCOUNT:ABC1234567
The file... (5 Replies)
Discussion started by: cinderella1
5 Replies
5. Shell Programming and Scripting
helloo
I wonder if there's a way to cut characters out of a string and keep only
the last 2 by using sed.
For example if there's the todays' date:
2012-05-06
and we only want to keep the last 2 characters which are the day.
Is there a quick way to do it with sed? (2 Replies)
Discussion started by: vlm
2 Replies
6. UNIX for Dummies Questions & Answers
Hello,
I have records like below that I want to remove any five characters from the end of the string before the double quotes unless it is only an asterik.
3919,5020 ,04/17/2012,0000000000006601.43,,0000000000000000.00,, 132, 251219,"*"
1668,0125 ... (2 Replies)
Discussion started by: jyoung
2 Replies
7. Shell Programming and Scripting
I just have a couple of quick questions.
I am having trouble with this cut. I am basically trying to cut the string so that i can insert the users guess at the appropriate point in the string.
$letters is the character count of the $word.
What it seems to do is cut the character into the... (0 Replies)
Discussion started by: Makaer
0 Replies
8. Shell Programming and Scripting
Hi All,
I have a string like "9633C01302_2". I need to extract the number(02) after "13" and before "_" and the number coming after "13" and before "_" is not constant, it keeps on changing...
Can some one plz help me wth the command..
i tried this echo "9633C01302_2" | cut -d'_' -f1 ..But... (2 Replies)
Discussion started by: grajesh_955
2 Replies
9. Shell Programming and Scripting
HI,
I want to cut end string from line.
e.g. i have following input line
/users/home/test.txt
I want to get end string 'test.txt' from above line and length of that end string will change and it always start after '/'.
Thanks,
Visu (7 Replies)
Discussion started by: visu
7 Replies
10. Shell Programming and Scripting
I am writing a script to search PCL output and append more PCL data to the end accordingly.
I need to remove the last 88 bytes from the string.
I have searched for a few hours now and am coming up with nothing. I can't use head or tail because the PCL output is all on one line. awk crashes on... (3 Replies)
Discussion started by: craig2k
3 Replies