06-23-2014
Can anyone optimize the above command , I am ruuning a 90 MB file and it is taking good amount of time to get the count of the pattern
Thanks
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I've written a script to count the total size of SAN storage LUNs, and also display the LUN sizes.
From server to server, the LUNs sizes differ.
What I want to do is count the occurances as they occur and change.
These are the LUN sizes:
49.95
49.95
49.95
49.95
49.95
49.95
49.95
49.95... (2 Replies)
Discussion started by: cyber111
2 Replies
2. Shell Programming and Scripting
i want to search a word in a file and find the count of occurences even if pattern occures twice in a same line.
for example file has the following content.
yes no no nooo yees
no yes
if I search for "no" it should give count as 4
Pls help.
Thanks (9 Replies)
Discussion started by: RahulJoshi
9 Replies
3. Shell Programming and Scripting
I need to count the number of occurrences of a pattern, say 'key', between each occurrence of a different pattern, say 'lu'.
Here's a portion of the text I'm trying to parse:
lu S1234L_149_m1_vg.6, part-att 1, vdp-att 1 p-reserver IID 0xdb
registrations:
key 4156 4353 0000 0000
... (3 Replies)
Discussion started by: slipstream
3 Replies
4. Shell Programming and Scripting
Hi
I have the following files in a directory -
ds_pl_W_Test
ds_pl_list_Test
ds_pl_list_Test
ds_pl_listl_Test
ds_pl_file_Test
ds_pl_xx_Test
I would like to count the number files in the directory that contain the word "list"
I tried the following but it returns zero -
... (3 Replies)
Discussion started by: Prega
3 Replies
5. Shell Programming and Scripting
Hi,
I had posted few days back and got replies on how to extract patterns from a file.
I had another question. I want to count the number of lines a particular pattern. I thought of somethings like using NF variable, etc, but they didnt work.
Here is sample input.
... (9 Replies)
Discussion started by: sandeepk1611
9 Replies
6. Shell Programming and Scripting
Hi all,
I need to search the database log find out the most frequently used tables for a certain period of time.
The search pattern is : the database.table
so, i need to look for ABCD.* in the entire log and then need the top ten tables.
I thought of using awk, search for the pattern ... (7 Replies)
Discussion started by: ysvsr1
7 Replies
7. UNIX for Dummies Questions & Answers
hi,
I have a text..and i need to find a pattern in the text and count to the no of times the pattern occured.
i have used grep command ..but the problem is , it shows the occurrences of the pattern but doesn't count no of times the pattern occuries. (5 Replies)
Discussion started by: nvnni
5 Replies
8. Shell Programming and Scripting
I am trying to search a file for a patterns ERR- in a file and return a count for each of the error reported
Input file is a free flowing file without any format
example of output
ERR-00001=5
....
ERR-01010=10
.....
ERR-99999=10 (4 Replies)
Discussion started by: swayam123
4 Replies
9. Shell Programming and Scripting
Guys -
Need your ideas on a section of code to finish something up. To make a long story short, I'm parsing a print output file that goes to pre-printed forms. I'm intercepting it, parsing it, formatting it, cutting it up into individual pages, grabbing the text I want in zones, building an... (3 Replies)
Discussion started by: ampsys
3 Replies
10. UNIX for Beginners Questions & Answers
I need to get a count of all the records that start with 4 and then print the value.
I have the below statement but it is missing something, can someone help me to fix this
awk 'BEGIN{~/^4/{C++}};END {print"<Total>"} {print"<Reg>"}{print "<value>"C"</value></Reg>"}' {print"</Total>"} temp >... (2 Replies)
Discussion started by: rosebud123
2 Replies
LEARN ABOUT DEBIAN
jocamlcp
JOCAMLCP(1) General Commands Manual JOCAMLCP(1)
NAME
Jocamlcp - The JoCaml profiling compiler
SYNOPSIS
jocamlcp [ jocamlcp options ] [ -p flags ] filename ...
DESCRIPTION
The jocamlcp command is a front-end to jocamlc(1) that instruments the source code, adding code to record how many times functions are
called, branches of conditionals are taken, ... Execution of instrumented code produces an execution profile in the file ocamlprof.dump,
which can be read using jocamlprof(1).
jocamlcp accepts the same arguments and options as jocamlc(1).
OPTIONS
In addition to the jocamlc(1) options, jocamlcp accepts the following option controlling the amount of profiling information:
-p letters
The letters indicate which parts of the program should be profiled:
a all options
f function calls : a count point is set at the beginning of each function body
i if ... then ... else: count points are set in both then and else branches
l 0 loops: a count point is set at the beginning of the loop body
m match branches: a count point is set at the beginning of the body of each branch of a pattern-matching
t try ... with branches: a count point is set at the beginning of the body of each branch of an exception catcher
For instance, compiling with jocamlcp -pfilm profiles function calls, if ... then ... else ..., loops, and pattern matching.
Calling jocamlcp(1) without the -p option defaults to -p fm meaning that only function calls and pattern matching are profiled.
Note: due to the implementation of streams and stream patterns as syntactic sugar, it is hard to predict what parts of stream expressions
and patterns will be profiled by a given flag. To profile a program with streams, we recommend using jocamlcp -p a.
SEE ALSO
jocamlc(1), jocamlprof(1).
The Objective Caml user's manual, chapter "Profiling".
JOCAMLCP(1)