Sponsored Content
Full Discussion: awk print pipe
Top Forums Shell Programming and Scripting awk print pipe Post 302707341 by Corona688 on Friday 28th of September 2012 11:31:53 AM
Old 09-28-2012
Leave off 'infile' and awk will read from standard input instead.
This User Gave Thanks to Corona688 For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

How do I get awk to print a " in it's print part?

The line is simple, use " '{ print $1"]"$2"\"$3THE " NEEDS TO GO HERE$4 }' I've tried \", "\, ^" and '"" but none of it works. What am I missing? Putting in the [ between $1 and $2 works fine, I just need to do the same with a ". Thanks. (2 Replies)
Discussion started by: LordJezo
2 Replies

2. Shell Programming and Scripting

Is it better to grep and pipe to awk, or to seach with awk itself

This may just be a lack of experience talking, but I always assumed that when possible it was better to use a commands built in abilities rather than to pipe to a bunch of commands. I wrote a (very simple) script a while back that was meant to pull out a certain error code, and report back what... (4 Replies)
Discussion started by: DeCoTwc
4 Replies

3. UNIX for Dummies Questions & Answers

grep pipe filename print issue

uname -a SunOS mypc 5.10 Generic_141414-07 sun4v sparc SUNW,SPARC-Enterprise-T2000 uname -a SunOS mypc 5.10 Generic_144488-07 sun4v sparc SUNW,SPARC-Enterprise-T5220 find . -name "*.cer" -exec keytool -v -list -printcert -file {} \; | grep -i "Aug 03" Valid from: Mon Jan 29 00:00:00 GMT... (16 Replies)
Discussion started by: shifahim
16 Replies

4. Shell Programming and Scripting

Pipe to awk to variable

Hi! If I'm trying something like: echo "hello world" | myvar=`awk -F "world" '{print $1}'` echo $myvar myvar is always empty :confused: I googled for houres now and don't understand why it isn't working... Trying it in normal bash. Can someone explain it to me so I can say "Of course!... (8 Replies)
Discussion started by: al0x
8 Replies

5. Programming

print all nonempty pipe

I am trying to write a shell script for Linux to print the names of all non empty pipes in the current directory? any help (3 Replies)
Discussion started by: nimesh
3 Replies

6. Shell Programming and Scripting

help with sed or awk with less pipe

<tr><th align=right valign=top>Faulty_Part</th><td align=left valign=top>readhat version 6.0</td></tr> <tr><th align=right valign=top>Submit_Date</th><td align=left valign=top>2011-04-28 02:08:02</td></tr> .......(a long string) I want to get all the field between "left valign=top>" and "... (2 Replies)
Discussion started by: yanglei_fage
2 Replies

7. Shell Programming and Scripting

BOTH pipe and file(s) into awk

Hello all, quick question: is it possible to pass input into AWK BOTH with a pipe AND a file at the same time, something like this: command .......|awk '.................' FILEIN > fileout All I read says either one or the other, not both, is it at all possible? And how would the... (2 Replies)
Discussion started by: gio001
2 Replies

8. Shell Programming and Scripting

Use less pipe for grep or awk sed to print the line not include xx yy zz

cat file |grep -v "xx" | grep -v "yy" |grep -v "zz" (3 Replies)
Discussion started by: yanglei_fage
3 Replies

9. Shell Programming and Scripting

awk pipe to sort

In the below awk to add a sort by smallest to largest should it be added after the END? Thank you :). BEGIN { FS="*" } # Read search terms from file1 into 's' FNR==NR { s next } { # Check if $5 matches one of the search terms for(i in s) { if($5 ~ i) { ... (4 Replies)
Discussion started by: cmccabe
4 Replies

10. Red Hat

Print Date when Broken Pipe happens

Hi all, as i have multiple broken pipes on ssh sessions, i need to find out after how much time it happens, ssh root@testServer root@testServer's password: ssh:notty Last login: Thu Apr 6 06:41:16 2017 from 10.10.10.2 # but when broke pipe happen i don't have any idea after how much... (3 Replies)
Discussion started by: charli1
3 Replies
PSREPORT(1)							   User Commands						       PSREPORT(1)

NAME
psreport: - report on the packets in a Program Stream SYNOPSIS
psreport [switches] <infile> DESCRIPTION
TS tools version 1.11, psreport built Nov 11 2008 17:15:47 Report on the packets in a Program Stream. Files: <infile> is an H.222 Program Stream file (but see -stdin) Switches: -stdin Input from standard input, instead of a file -verbose, -v Output packet data as well. -max <n>, -m <n> Maximum number of PS packets to read -dvd The PS data is from a DVD. This is the default. This switch has no effect on MPEG-1 PS data. -notdvd, -nodvd The PS data is not from a DVD. The DVD specification stores AC-3 (Dolby), DTS and other audio in a specialised manner in pri- vate_stream_1. TS tools version 1.11, psreport built Nov 11 2008 17:15:47 Report on the packets in a Program Stream. Files: <infile> is an H.222 Program Stream file (but see -stdin) Switches: -stdin Input from standard input, instead of a file -verbose, -v Output packet data as well. -max <n>, -m <n> Maximum number of PS packets to read -dvd The PS data is from a DVD. This is the default. This switch has no effect on MPEG-1 PS data. -notdvd, -nodvd The PS data is not from a DVD. The DVD specification stores AC-3 (Dolby), DTS and other audio in a specialised manner in pri- vate_stream_1. SEE ALSO
The full documentation for psreport is maintained as a Texinfo manual. Please check http://tstools.berlios.de for more information. psreport 1.11 November 2008 PSREPORT(1)
All times are GMT -4. The time now is 12:50 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy