RE: How to get unique value using AWK?

2004-01-22 Thread Simpson, Ken
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Thursday, January 22, 2004 11:09 AM To: Multiple recipients of list ORACLE-L Subject: How to get unique value using AWK? Hi All, My manager wants to get all the unique

RE: How to get unique value using AWK?

2004-01-22 Thread Jamadagni, Rajendra
pipe it through uniq Raj Rajendra dot Jamadagni at nospamespn dot com All Views expressed in this email are strictly personal. QOTD: Any clod can have facts, having an opinion is an art ! -Original Message-

Re: How to get unique value using AWK?

2004-01-22 Thread Mladen Gogala
There is much improved version of awk called perl and it has something called hashes. Code snippet would look something like this: my %Godot; while (} { chomp; if (/\'([^\']+)/ { next if exists $Godot{$1}; $Godot{$1}=undef; } } foreach (sort keys %Godot) { print $_\n; } On 01/22/2004

RE: How to get unique value using AWK?

2004-01-22 Thread Ed
On Thu, 2004-01-22 at 10:34, Simpson, Ken wrote: How about piping it through uniq? uniq normally assumes the input is sorted. See my other response. Best, -- Edward Simmonds RHCE, OCP - Real men don't send html email. -- Please see the official ORACLE-L FAQ: http://www.orafaq.net --

RE: How to get unique value using AWK?

2004-01-22 Thread Nikhil Khimani
Try this ... $ grep -i WAIT devdb1_ora_989.trc_orig|awk '{print $3 $4 $5 $6}'| sort -u Thanks, Nikhil -Original Message- Sent: Thursday, January 22, 2004 11:09 AM To: Multiple recipients of list ORACLE-L Hi All, My manager wants to get all the unique wait events from the trace

RE: How to get unique value using AWK?

2004-01-22 Thread Bellow, Bambi
uniq is not ubiq. If uniq doesn't do it for you, do sort -u -Original Message- Sent: Thursday, January 22, 2004 10:34 AM To: Multiple recipients of list ORACLE-L -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent:

RE: How to get unique value using AWK?

2004-01-22 Thread Kirtikumar Deshpande
Why not process the trace file with 9i tkprof? It will nicely summarize the wait times for those events. After seeing those unique wait events, your boss may ask for the wait times next!! Be proactive :) - Kirti --- Simpson, Ken [EMAIL PROTECTED] wrote: -Original Message-

Re: How to get unique value using AWK?

2004-01-22 Thread Mladen Gogala
On 01/22/2004 12:04:35 PM, Bellow, Bambi wrote: uniq is not ubiq. If uniq doesn't do it for you, do sort -u Why would you things that way when you can do them in perl? -- Please see the official ORACLE-L FAQ: http://www.orafaq.net -- Author: Mladen Gogala INET: [EMAIL PROTECTED] Fat City Network

Re: How to get unique value using AWK?

2004-01-22 Thread Ed
On Thu, 2004-01-22 at 10:09, [EMAIL PROTECTED] wrote: Hi All, My manager wants to get all the unique wait events from the trace file. I tried the below but how do i get DISTICT wait event name? Any help would be really appreciated. grep -i WAIT devdb1_ora_989.trc_orig|awk '{print $3

Re: How to get unique value using AWK?

2004-01-22 Thread dhill
Jay - Try: $ grep -i WAIT devdb1_ora_989.trc_orig|awk '{print $3 $4 $5 $6}' | sort | uniq | more HTH, Dave Hi All, My manager wants to get all the unique wait events from the trace file. I tried the below but how do i get DISTICT wait event name? Any help would be really

RE: How to get unique value using AWK?

2004-01-22 Thread Bellow, Bambi
That goes both ways, my friend. :) -Original Message- Sent: Thursday, January 22, 2004 11:40 AM To: Multiple recipients of list ORACLE-L On 01/22/2004 12:04:35 PM, Bellow, Bambi wrote: uniq is not ubiq. If uniq doesn't do it for you, do sort -u Why would you things that way when

Re: RE: How to get unique value using AWK?[CLOSED]

2004-01-22 Thread jaysingh1
Thanks Kirti and everyone who responded. This forum is really great. - Original Message - Date: Thursday, January 22, 2004 12:14 pm Why not process the trace file with 9i tkprof? It will nicely summarize the wait times for those events. After seeing those unique wait events, your

RE: How to get unique value using AWK?

2004-01-22 Thread DENNIS WILLIAMS
Reminder to post to freelists.org per Jared - I'm crossposting this reply. Jay Pipe your output to sort, then uniq. grep -i WAIT devdb1_ora_989.trc_orig|awk '{print $3 $4 $5 $6}'|sort|uniq Dennis Williams DBA Lifetouch, Inc. [EMAIL PROTECTED] -Original Message- Sent: Thursday,

Re: How to get unique value using AWK?

2004-01-22 Thread Jared . Still
:Re: How to get unique value using AWK? There is much improved version of awk called perl and it has something called hashes. Code snippet would look something like this: my %Godot; while (} { chomp; if (/\'([^\']+)/ { next if exists $Godot{$1}; $Godot{$1}=undef; } } foreach (sort