Sponsored Content
Top Forums Shell Programming and Scripting Addition as part of uniq command Post 302557618 by cfajohnson on Wednesday 21st of September 2011 05:17:28 PM
Old 09-21-2011
Quote:
Originally Posted by tamil.pamaran
I would like to know if this is possible with any commands other than awk family. Please clarify.

It can be done with any programming language, e.g., perl, python, ruby, shell (while loop), sed, etc....
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

uniq command???

HI, Please tell the usage of uniq command in UNIX with example Thanks (2 Replies)
Discussion started by: skyineyes
2 Replies

2. Shell Programming and Scripting

Help with uniq command

I call.... cat 1.txt | uniq -c Sample of whats in 1.txt vmstat cd exit w cd cd cd newgrp xinit f cd cd cd rlogin (2 Replies)
Discussion started by: Bandit390
2 Replies

3. UNIX for Dummies Questions & Answers

Uniq command behaving odd

My file has k s j v l k a s f l k s a d f j l a s (3 Replies)
Discussion started by: phoenix_nebula
3 Replies

4. UNIX for Dummies Questions & Answers

Several file comparison not uniq or comm command

When comparing several files is there a way to find values unique to each file? File1 a b c d File2 a b t File 3 a (3 Replies)
Discussion started by: dr_sabz
3 Replies

5. Shell Programming and Scripting

Uniq Command?

Hello, I have a file with a list of car makes and specific information for each make. An example is: @Audi:Warranty @Audi:Pricing @Audi:Colors @Acura:Warranty @Acura:Pricing @Acura:Colors and so on through a bunch of makes. I need to make a list in a selection box of just one name of... (12 Replies)
Discussion started by: macbb1117
12 Replies

6. UNIX for Advanced & Expert Users

uniq command

at which situation uniq command fails. How to delete/remove duplicate lines in an unix file (1 Reply)
Discussion started by: tp2115
1 Replies

7. UNIX for Dummies Questions & Answers

Re: How To Use UNIQ UNIX Command On single Column

Hi , Can You Please let Know How use unix uniq command on a single column for deleting records from file with Below Structure.Pipe Delimter File . Source Name | Account_Id A | 101 B... (2 Replies)
Discussion started by: anudeepkumar123
2 Replies

8. Shell Programming and Scripting

cat and uniq command

Hello i have tried to retrieve a distinct list of data from a file with a command combination but the uniq command line is not filtering the fields repeated. Can someone help me ? here is the file input 3837734|LAUNCH TEST01 3837735|LAUNCH TEST01 3837736|LAUNCH TEST01 3837737|LAUNCH... (4 Replies)
Discussion started by: ade05fr
4 Replies

9. Shell Programming and Scripting

Command line arguments for addition

Hi all, I am trying to write a code for addition of n numbers which will be passed by the user as command line arguments. I wrote the following code. add=0 for (( i = 1 ; i <= $# ; i++ )) do add=`expr $i + $add` done #echo "sum is : $add" input : $./add.sh 12 32 14... (7 Replies)
Discussion started by: PranavEcstasy
7 Replies

10. Shell Programming and Scripting

Trying to find the distinct lines using uniq command

Platform :Oracle Linux 6.4 Shell : bash The below file has 7 lines , some of them are duplicates. There are only 3 distinct lines. But why is the uniq command still showing 7 ? I just want the distinct lines to be returned. $ cat test.txt SELECT FC.COORD_SET_ID FROM OM_ORDER_FLOW F, -... (2 Replies)
Discussion started by: kraljic
2 Replies
PTS_LISTENTRIES(1)					       AFS Command Reference						PTS_LISTENTRIES(1)

NAME
pts_listentries - Displays all users or groups in the Protection Database SYNOPSIS
pts listentries [-users] [-groups] [-cell <cell name>] [-noauth] [-localauth] [-force] [-help] pts liste [-u] [-g] [-c <cell name>] [-n] [-l] [-f] [-h] DESCRIPTION
The pts listentries command displays the name and AFS ID of all Protection Database entries of the indicated type. It also displays the AFS ID of each entry's owner and creator. To display all user and machine entries, either include the -users flag or omit both it and the -groups flag. To display all group entries, include the -groups flag. To display all entries, provide both flags. OPTIONS
-users Displays user and machine entries. -groups Displays group entries. -cell <cell name> Names the cell in which to run the command. For more details, see pts(1). -force Enables the command to continue executing as far as possible when errors or other problems occur, rather than halting execution at the first error. -help Prints the online help for this command. All other valid options are ignored. -localauth Constructs a server ticket using a key from the local /etc/openafs/server/KeyFile file. Do not combine this flag with the -cell or -noauth options. For more details, see pts(1). -noauth Assigns the unprivileged identity anonymous to the issuer. For more details, see pts(1). OUTPUT
The output includes a line for each entry, with information in four columns that have the following headers: Name The entry's name. ID The entry's AFS ID (AFS UID for a user or machine, negative AFS GID for a group). Owner The AFS ID of the user or group that owns the entry. Creator The AFS ID of the user who created the entry (the system:administrators group is listed as the creator of the entry for "anonymous" and the system groups, but it is not otherwise possible for a group to create groups). In general, the entries appear in the order in which they were created. EXAMPLES
The following example displays both user and group entries. % pts listentries -users -groups Name ID Owner Creator system:administrators -204 -204 -204 system:anyuser -101 -204 -204 system:authuser -102 -204 -204 anonymous 32766 -204 -204 admin 1 -204 32766 pat 100 -204 1 smith 101 -204 1 pat:friends -206 100 100 staff -207 -204 1 PRIVILEGE REQUIRED
The issuer must belong to the system:administrators group. SEE ALSO
pts(1), pts_creategroup(1), pts_createuser(1), pts_examine(1) COPYRIGHT
IBM Corporation 2000. <http://www.ibm.com/> All Rights Reserved. This documentation is covered by the IBM Public License Version 1.0. It was converted from HTML to POD by software written by Chas Williams and Russ Allbery, based on work by Alf Wachsmann and Elizabeth Cassell. OpenAFS 2014-04-08 PTS_LISTENTRIES(1)
All times are GMT -4. The time now is 06:21 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy