I need to find the line count of multiple strings in a particular file. The strings are as follows:
bmgcc
bmgccftp
bsmsftp
bulkftp
cctuneftp
crbtftp
crmpos
cso
gujhr
I am doing manual grep for each of the string to find the line count. The command i am using right now is:
grep mark... (3 Replies)
Hello,
I'm looking for a wait to count the number of occurrences of a certain string of characters within a file. The file that I trying to parce has segments within the file that have a header and footer to each segment and I'm trying to do a count of the header string and compare it to a count... (9 Replies)
Hi All,
I have a below file:
==================
02:53 pravin-root
02:53 pravin-root
03:05 pravin-root
02:55 pravin1-root
02:59 pravin1-root
==================
How do I find the first and last value of column 1. For example, how do I find 02:53 is the first time stamp and 03:05 is... (3 Replies)
I am writing a package manager in BASH and I would like a small snippet of code that finds lines that match exact input and count them. For example, my file contains:
xyz
xyz-lib2.0+
xyz-lib2.0
xyz-lib1.5
and "grep -c xyz" returns 4.
The current function is:
# $1 is the package name.... (3 Replies)
I have a file containing about 5 million rows, in the file there are some records which has extra delimiter at random position. (we dont know the positions), now we have to Count the delimeter from each row and if the count of delimeter is not matching then I want to delete those rows from the... (5 Replies)
Hi Guys,
The script which I am using works really good for finding the file count for files that are not symlink. I know I can use find command like:
find . -type l | wc -l
This way I can get filecount of the symlink but is there a one liner to use -type l and -type f option ? That is... (4 Replies)
How to find count total number of pattern in a file …
File contains : a.txt
-------------
aaa bbb nnn
ccc aaa bbb
aaa ddd aaa
aaa aaa aaa
grep -c aaa a.txt
Op: 4 ( But my requirement is should count the total no of patterns as 7 ) (4 Replies)
I'm trying to use awk to count the occurrences of two matching fields of a CSV file.
For instance, for data that looks like this...
Joe,Blue,Yes,No,High
Mike,Blue,Yes,Yes,Low
Joe,Red,No,No,Low
Joe,Red,Yes,Yes,Low
I've been trying to use code like this...
countvar=`awk ' $2~/$color/... (4 Replies)
Hi,
I have a file with a list of bunch of IP addresses from different VLAN's . I am trying to find the list the number of each vlan occurence in the output
Here is how my file looks like
1.1.1.1
1.1.1.2
1.1.1.3
1.1.2.1
1.1.2.2
1.1.3.1
1.1.3.2
1.1.3.3
1.1.3.4
So what I am trying... (2 Replies)
Discussion started by: new2prog
2 Replies
LEARN ABOUT DEBIAN
rt::client::rest::transaction
RT::Client::REST::Transaction(3pm) User Contributed Perl Documentation RT::Client::REST::Transaction(3pm)NAME
RT::Client::REST::Transaction -- this object represents a transaction.
SYNOPSIS
my $transactions = $ticket->transactions;
my $count = $transactions->count;
print "There are $count transactions.
";
my $iterator = $transactions->get_iterator;
while (my $tr = &$iterator) {
print "Id: ", $tr->id, "; Type: ", $tr->type, "
";
}
DESCRIPTION
A transaction is a second-class citizen, as it does not exist (at least from the current REST protocol implementation) by itself. At the
moment, it is always associated with a ticket (see parent_id attribute). Thus, you will rarely retrieve a transaction by itself; instead,
you should use "transactions()" method of RT::Client::REST::Ticket object to get an iterator for all (or some) transactions for that
ticket.
ATTRIBUTES
id
Numeric ID of the transaction.
creator
Username of the user who created the transaction.
parent_id
Numeric ID of the object the transaction is associated with.
type
Type of the transactions. Please referer to RT::Client::REST documentation for the list of transaction types you can expect this field
to contain. Note that there may be some transaction types not (dis)covered yet.
old_value
Old value.
new_value
New value.
field
Name of the field the transaction is describing (if any).
attachments
I have never seen it set to anything yet. (I will some day investigate this).
created
Time when the transaction was created.
content
Actual content of the transaction.
description
Human-readable description of the transaction as provided by RT.
data
Not sure what this is yet.
METHODS
RT::Client::REST::Transaction is a read-only object, so you cannot "store()" it. Also, because it is a second-class citizen, you cannot
"search()" or "count()" it -- use "transactions()" method provided by RT::Client::REST::Ticket.
retrieve
To retrieve a transaction, attributes id and parent_id must be set.
INTERNAL METHODS
rt_type
Returns 'transaction'.
SEE ALSO
RT::Client::REST, RT::Client::REST::Ticket, RT::Client::REST::SearchResult.
AUTHOR
Dmitri Tikhonov <dtikhonov@yahoo.com>
LICENSE
Perl license with the exception of RT::Client::REST, which is GPLed.
perl v5.14.2 2011-12-27 RT::Client::REST::Transaction(3pm)