10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello All,
While searching for the question, I found some answers but my implementation is not giving expected output.
I have two files; one is sourcefile, other is named template.
What I want to do is to search each line in template, when found all columns, cut the matching line from source... (4 Replies)
Discussion started by: baris35
4 Replies
2. Shell Programming and Scripting
Hi Friends,
I have a file1
i want to retrieve only the fields which have DEP,CITY,TRANS as headers in other file.
Output:
I want to give the input as DEP,CITY,TRANS column names to get the output.
i used cut command .. but if i have 300 fileds it is more difficult to... (4 Replies)
Discussion started by: i150371485
4 Replies
3. Shell Programming and Scripting
Hi
Description of input file I have:
-------------------------
1) CSV with double quotes for string fields.
2) Some string fields have Comma as part of field value.
3) Have Duplicate lines
4) Have 200 columns/fields
5) File size is more than 10GB
Description of output file I need:... (4 Replies)
Discussion started by: krishnix
4 Replies
4. Shell Programming and Scripting
HI,
I have a file like below
"103865","103835","Zming","","Zhu","103965","Sunnyvale","US",
"116228","116227","Morlla","","Kowalski","113228","Paese "(Treviso)""IT"
I want to validate the 7th column which is below.
"Sunnyvale"
"Paese
In the above 7th column Paese is not ended with... (9 Replies)
Discussion started by: Krrishv
9 Replies
5. UNIX for Dummies Questions & Answers
Hi,
Let's say that I have a file called table, I know that if I need to see a the second column for exampls I use:
awk ' {print $2}' table.txt
Is there anyway to use awk to actually cut a column and put it somewhere else in the table?:confused: (8 Replies)
Discussion started by: cosmologist
8 Replies
6. Shell Programming and Scripting
Is there a betterway to cut certain columns in everyline based on positions.
Basically, I have a largefile and eachline is of 1000 characters and I need to cut the characters 17-30, 750-775, 776-779, 780-805
while
do
fptr=`cat $tempfile | head -$i | tail -1`
... (4 Replies)
Discussion started by: gunaah
4 Replies
7. Shell Programming and Scripting
Hi
I have the input file as below
***TEST10067
00567GROSZ 099
00567CTCTSDS90
***TEST20081
08233GROZWEWE
00782GWERW899
***TEST30088
08233GROZWEWE
00782GWERW899
I am finding the lines starting with *** and outputing as below
TEST10067
TEST20081
TEST30088
I need a space between TEST1... (9 Replies)
Discussion started by: dhanamurthy
9 Replies
8. Shell Programming and Scripting
Hi
I have a file.
In Each and every line, i want to cut the position from 130 to 134 and
need to check if it is XXXX then
i need to replace with YYYY (Only from 130 to 134).
Your help is very much appriciated. (4 Replies)
Discussion started by: senthil_is
4 Replies
9. Shell Programming and Scripting
Hi
Is there a way to cut the last two characters off a word or number given that this word or number can be of varying length?
I have tried something like
TEST=`echo $OLD | cut -c 1-5`
where $OLD is a variable containing a number like 1234567 which gives a result of 12345. This is fine... (4 Replies)
Discussion started by: rleebife
4 Replies
10. Shell Programming and Scripting
I am trying to cut and delete using sed and redirect back into the file. This is not working write. When testing the script, it hangs. Any idea what I am doing wrong here.
################ Reads the input file to cut volumes for returns and CUT_ERVTAPE_FILE()
{
echo "working on cut... (2 Replies)
Discussion started by: gzs553
2 Replies