Sponsored Content
Full Discussion: Count incrementation
Top Forums Shell Programming and Scripting Count incrementation Post 31020 by itsupplies on Thursday 31st of October 2002 05:11:33 AM
Old 10-31-2002
Also can use:

(( CNT +=1 ))

Smilie
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to count the record count in an EBCDIC file.

How do I get the record count in an EBCDIC file on a Linux Box. :confused: (1 Reply)
Discussion started by: oracle8
1 Replies

2. UNIX for Dummies Questions & Answers

Sorting using count, grep and count

Hi, I trying to sort information in a file by making count for every object. For example: A B A D A B C i would like to sort out count for each object (A's, B's and etc) but in actual case i dont know the object but i know the position ofthe object. do i need to use array as well? Any... (2 Replies)
Discussion started by: sukhpal_78
2 Replies

3. Shell Programming and Scripting

Getting Sum, Count and Distinct Count of a file

Hi all this is a UNIX question. I have a large flat file with millions of records. col1|col2|col3 1|a|b 2|c|d 3|e|f 3|g|h footer**** I am supposed to calculate the sum of col1 1+2+3+3=9, count of col1 1,2,3,3=4, and distinct count of col1 1,2,3=c3 I would like it if you avoid... (4 Replies)
Discussion started by: singhabhijit
4 Replies

4. Shell Programming and Scripting

count identical strings print last row and count

I have a sorted file like: Apple 3 Apple 5 Apple 8 Banana 2 Banana 3 Grape 31 Orange 7 Orange 13 I'd like to search $1 and if $1 is not the same as $1 in the previous row print that row and print the number of times $1 was found. so the output would look like: Apple 8 3 Banana... (2 Replies)
Discussion started by: dcfargo
2 Replies

5. Shell Programming and Scripting

Count the delimeter from a file and delete the row if delimeter count doesnt match.

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)
Discussion started by: Akumar1
5 Replies

6. Shell Programming and Scripting

awk - count character count of fields

Hello All, I got a requirement when I was working with a file. Say the file has unloads of data from a table in the form 1|121|asda|434|thesi|2012|05|24| 1|343|unit|09|best|2012|11|5| I was put into a scenario where I need the field count in all the lines in that file. It was simply... (6 Replies)
Discussion started by: PikK45
6 Replies

7. Shell Programming and Scripting

Compare file1 header count with file2 line count

What I'm trying to accomplish. I receive a Header and Detail file for daily processing. The detail file comes first which holds data, the header is a receipt of the detail file and has the detail files record count. Before processing the detail file I would like to put a wrapper around another... (4 Replies)
Discussion started by: pone2332
4 Replies

8. Shell Programming and Scripting

Error files count while coping files from source to destination locaton as well count success full

hi All, Any one answer my requirement. I have source location src_dir="/home/oracle/arun/IRMS-CM" My Target location dest_dir="/home/oracle/arun/LiveLink/IRMS-CM/$dc/$pc/$ct" my source text files check with below example.text file content $fn "\t" $dc "\t" $pc "\t" ... (3 Replies)
Discussion started by: sravanreddy
3 Replies

9. Shell Programming and Scripting

Count the pipes "|" in line and delete line if count greter then number.

Hello, I have been working on Awk/sed one liner which counts the number of occurrences of '|' in pipe separated lines of file and delete the line from files if count exceeds "17". i.e need to get records having exact 17 pipe separated fields(no more or less) currently i have below : awk... (1 Reply)
Discussion started by: ketanraut
1 Replies

10. UNIX for Beginners Questions & Answers

How to find the count of IP addresses that belong to different subnets and display the count?

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
PSEND(3PVM)							  PVM Version 3.4						       PSEND(3PVM)

NAME
pvm_psend - Pack and send data in one call. SYNOPSIS
C int info = pvm_psend( int tid, int msgtag, char *buf, int len, int datatype ) Fortran call pvmfpsend( tid, msgtag, buf, len, datatype, info ) PARAMETERS
tid Integer task identifier of destination process. msgtag Integer message tag supplied by the user. msgtag should be >= 0. buf Pointer to a buffer to send. len Length of buffer (in multiple of data type size). datatype Type of data to which buf points (see below). info Integer status code returned by the routine. DESCRIPTION
The routine pvm_psend takes a pointer to a buffer buf its length len and its data type datatype and sends this data directly to the PVM task identified by tid. msgtag is used to label the content of the message. If pvm_psend is successful, info will be 0. If some error occurs then info will be < 0. pvm_psend data can be received by pvm_precv, pvm_recv, pvm_trecv, or pvm_nrecv. The pvm_psend routine is asynchronous. Computation on the sending processor resumes as soon as the buffer is safe for reuse. This is in contrast to synchronous communication, during which computation on the sending processor halts until the matching receive is executed by the receiving processor. In C the datatype parameter must be one of the following, depending on the type of data to be sent: [Version 3.3.0 - This parameter only determines message length, not data conversion. It only sends raw bytes] datatype Data Type PVM_STR string PVM_BYTE byte PVM_SHORT short PVM_INT int PVM_FLOAT real PVM_CPLX complex PVM_DOUBLE double PVM_DCPLX double complex PVM_LONG long integer PVM_USHORT unsigned short int PVM_UINT unsigned int PVM_ULONG unsigned long int In Fortran the same data types specified for pack should be used. The PVM model guarantees the following about message order. If task 1 sends message A to task 2, then task 1 sends message B to task 2, message A will arrive at task 2 before message B. Moreover, if both messages arrive before task 2 does a receive, then a wildcard receive will always return message A. pvm_psend does not affect the state of the current outgoing message buffer (created by pvm_initsend and used by pvm_send). WARNINGS
In some versions of PVM (CM5, I860 and PGON), messages sent using pvm_psend must be received only by pvm_precv, likewise those sent with pvm_send must be received by pvm_recv, pvm_nrecv or pvm_trecv. pvm_psend is not compatible with pvm_recv (nor pvm_send with pvm_precv). In addition, pvm_probe is not interoperable with pvm_psend. This problem occurs because nonstandard message headers are used for efficiency in the pvm_psend function. In the generic Unix version of PVM, the calls are fully interoperable. The message tag space is shared between pvm_send and pvm_psend, so you must be careful to avoid selecting the wrong message (for example by using a wildcard to match the message). EXAMPLES
C: info = pvm_psend( tid, msgtag, array, 1000, PVM_FLOAT ); Fortran: CALL PVMFPSEND( TID, MSGTAG, BUF, CNT, REAL4, INFO ) ERRORS
These error conditions can be returned by pvm_psend PvmBadParam giving an invalid tid, msgtag, or datatype. PvmSysErr pvmd not responding. SEE ALSO
pvm_precv(3PVM), pvm_send(3PVM) 15 March, 1994 PSEND(3PVM)
All times are GMT -4. The time now is 09:19 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy