10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
I am facing an issue while cutting fields with comma delimiter. There are many records with Double quotes in between.
My data: aaa,bbb,"ccc, ddd",eee,fff,"ggg ,hhh",iii
When i use cut command with comma delimiter, i am getting wrong data like
field1=aaa
field2=bbb
field3="ccc... (3 Replies)
Discussion started by: krishna_gnv
3 Replies
2. Shell Programming and Scripting
Need help to append a pipe at end of the line immediately after the cut command,
I have an Input flat file with 16 feilds and I am removing the 16th feild by using the cut command as shown,
Input:
354|||||CORPORTATION||||NENE PARADE|||WISBECH|CAMBRIDGESHIRE|PE13 3BY|100001|
I... (5 Replies)
Discussion started by: Aditya_001
5 Replies
3. Shell Programming and Scripting
I am writing a shell script to skip couple of feilds in a flat file and as a part of this I have written the below piece of code in it.
cut -d '|' -f 1-17,19-31 $1 > filename
To add pipe at end of the line I used below command, but it adds even to header and footer as well which i... (11 Replies)
Discussion started by: Aditya_001
11 Replies
4. Shell Programming and Scripting
let i have A file and B file
A has contains 4 fields as below
----------------
f1 f2 f3 f4
B file consists of 5 fields as below
--------------------
f5 f6 f7 f8 f9
need to display as below output:
f5 f1 f3 f8 f9 (2 Replies)
Discussion started by: ANSHUMAN1983
2 Replies
5. Shell Programming and Scripting
I am trying to grep the oracle erros evry day from the logs file. My problem is :
-rw-r----- 1 tibcolm tibco 17438361 Apr 5 11:59 RetryService-RetryService.log
-rw-r----- 1 tibcolm tibco 245303 Apr 5 12:00 ResponseService-ResponseService.log
-rw-r----- 1 tibcolm tibco 2122654 Apr 5 12:00... (4 Replies)
Discussion started by: neeraj617
4 Replies
6. Shell Programming and Scripting
Hi,
I got a line of text which has spaces in between and it is a long stream of characters. I want to extract the text from certain position. Below is the line and I want to take out 3 characters from 86 to 88 character position. In this line space is also a character. However when using cut... (5 Replies)
Discussion started by: asutoshch
5 Replies
7. Shell Programming and Scripting
Hi! I'm a newbie and can't find the exact sed to make this work. I've installed CentOS and am trying to pass variables to a network-config file.
variables:
$ipAddress
$netmask
$gateway
file:
DeviceList.Ethernet.eth0.IP=192.168.1.10
DeviceList.Ethernet.eth0.Netmask=255.255.255.0... (5 Replies)
Discussion started by: greipr
5 Replies
8. Shell Programming and Scripting
I've got a file that contains a large list of links in this type of style:
'home_dir\2009\09\01\file.html'
I'd like to cut off all of the characters left of 'file.html'. I tried:
cat file.txt | cut -d\ -f4
but it told me that I had an invalid delimiter.
So I tried:
cat... (5 Replies)
Discussion started by: Rally_Point
5 Replies
9. UNIX for Advanced & Expert Users
I have a program. Everytime that I run that program ,it prints a disclaimer msg and prompts the user to accept the agreement (i.e: type 'y' or 'n').
Now I want to run the program multiple times with different inputs. So I wrote a script which runs in a loop and calls the program multiple times.... (2 Replies)
Discussion started by: the_learner
2 Replies
10. Shell Programming and Scripting
hi, sorry for asking what I am sure is a really easy question, I am wanting to cut the users real name from the output of 'finger'.
$ cut -f2-3 filename
is in my script but it only seems to cut the first line.
I need to cut the 2nd and 3rd word from each line and store them in variables... (1 Reply)
Discussion started by: rorey_breaker
1 Replies