10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
Extremely new to Perl scripting, but need a quick fix without using TEXT::CSV
I need to read in a file, pass any delimiter as an argument, and convert it to bar delimited on the output. In addition, enclose fields within double quotes in case of any embedded delimiters.
Any help would... (2 Replies)
Discussion started by: JPB1977
2 Replies
2. Shell Programming and Scripting
Hi,
I have a No Delimiter variable length text file with following schema -
Column Name Data length
Firstname 5
Lastname 5
age 3
phoneno1 10
phoneno2 10
phoneno3 10
sample data - ... (16 Replies)
Discussion started by: Gaurav Martha
16 Replies
3. Shell Programming and Scripting
Hi all,
I have a number of strings like below:
//mnt/autocor/43°13'(33")W/
and i'm trying to get the numbers in this string, for example
431333
please help
thanks ahead (14 Replies)
Discussion started by: sunnydanniel
14 Replies
4. UNIX for Dummies Questions & Answers
Hi all,
I promise this is my very last dumb question.. but how to you count how many unique names you have.
My dataset is:
>Bac1
afdsgrr
>Bac4
egege
>Bac8
dgrjh
>Bac1
afdsgrr
>Bac1
afdsgrr
>Bac8
dgrjh
What i want to know is that how many unique names there is, so the output would... (3 Replies)
Discussion started by: Iifa
3 Replies
5. Shell Programming and Scripting
HI,
i have a file like this
t.txt
f1|_f2|_
f1|_f2|_
f1|_f2|_
as if col delimiter is |_ and row delimiter |_\n
trying to count number of records using awk
$ awk 'BEGIN{FS="|_" ; RS="~~\n"} {n++}END{print n} ' t.txt
7
wondering how can i count this to 3 ?
thx (9 Replies)
Discussion started by: aksforum
9 Replies
6. Shell Programming and Scripting
I’m new to Linux script and not sure how to filter out bad records from huge flat files (over 1.3GB each). The delimiter is a semi colon “;”
Here is the sample of 5 lines in the file:
Name1;phone1;address1;city1;state1;zipcode1
Name2;phone2;address2;city2;state2;zipcode2;comment... (7 Replies)
Discussion started by: lv99
7 Replies
7. Shell Programming and Scripting
Hi,
The following output shows how many pmon process are started by users named : oracle or yoavb
$ ps -ef |grep pmon |grep -v grep |grep -v ipmon
oracle 11268 1 0 Sep 2 ? 36:00 ora_pmon_qerp
oracle 17496 1 0 Oct 11 ? 8:58 ora_pmon_bcv
oracle 15081 1 0 ... (5 Replies)
Discussion started by: yoavbe
5 Replies
8. Shell Programming and Scripting
Hi,
I have a string like ABC.123.XYZ-A1-B2-P1-C4. I want to delimit the string based on "-" and then get result as only two strings. One with string till last hyphen and other with value after last hyphen... For this case, it would be something like first string as "ABC.123.XYZ-A1-B2-P1" and... (6 Replies)
Discussion started by: gupt_ash
6 Replies
9. Shell Programming and Scripting
Hi,
I want to count how many rows are in a file for a specific column.
eg.
K NM
K NM
K NM
K JK
K NM
K JK
K NM
so the file is tab-delimited. I want to count how many rows are in column 2 and how many NMs there are.
I used awk
awk '{OFS="\t"}; {count++} {print i,... (3 Replies)
Discussion started by: phil_heath
3 Replies
10. Shell Programming and Scripting
My data is something like shown below.
date1 date2 aaa bbbb ccccc
date3 date4 dddd eeeeeee ffffffffff ggggg hh
I want the output like this
date1date2 aaa eeeeee
I serached in the forum but didn't find the exact matching solution. Please help. (7 Replies)
Discussion started by: rdhanek
7 Replies