04-24-2012
Thanks a lot, this is indeed far more easy
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hello
I would like to perform a select from a oracle table and return those values to my shell script
For example:
site=head -1 $infile | cut -c1-15 | awk '{printf "s%", $0}
sqlplus -s /nolog |& #Open pipe to sql
select col1, col2, col3, col4
from oracle_table
where col5 =... (6 Replies)
Discussion started by: houtakker
6 Replies
2. UNIX for Dummies Questions & Answers
ls -ltr | grep string
How can I use regular expressions to filter the results provided even more. I am using the above command as a reference. (1 Reply)
Discussion started by: ckandreou
1 Replies
3. UNIX for Dummies Questions & Answers
I'm using the command grep -l XYZ to get a list of files containing the string XYZ. Then I using the comand ls -l ABC to get the create date timestamp of the each file. I've tried combining the comands using the pipe command, grep -l XYZ | ls -l, but its not working. What am I doing wrong? (3 Replies)
Discussion started by: jhtate
3 Replies
4. Shell Programming and Scripting
Hello,
I'm using csh. I have a file named "setup" that I normally source, e.g.
source setupI'd like a one-liner that sources this file, but excluding lines that contain "DEBUG", e.g.
cat setup | grep -v DEBUG | sourceOf course, the above does not work. How can I execute the results of a... (5 Replies)
Discussion started by: acheong87
5 Replies
5. Shell Programming and Scripting
Hi All ,
Is there any way to replace the pipe ( | ) with the broken pipe (0xA6) in unix (1 Reply)
Discussion started by: saj
1 Replies
6. Shell Programming and Scripting
I have an overnight script which runs across a large directory to repair permissions and ownership. I also have this command output the list of files affected so that cron can email these as a log file. Previously I had the command in the form:
find /path/to/files -not -user myname -print -exec... (4 Replies)
Discussion started by: mij
4 Replies
7. Shell Programming and Scripting
Hi,
Need help with a sed command that I am using to substitute 3 positions of a pipe delimited file.
i am getting different results while substituting the same position of two different files with the same value. Please see details below:
$ cat chk2
... (3 Replies)
Discussion started by: vmenon
3 Replies
8. Shell Programming and Scripting
Hello ,
When using vim, can ctag and cscope support recording search results and displaying the history results ? Once I jump to one tag, I can use :tnext to jump to next tag, but how can I display the preview search result? (0 Replies)
Discussion started by: 915086731
0 Replies
9. UNIX for Dummies Questions & Answers
I am using grep to match a pattern, but the output is strange.
$ grep -r -o "pattern" *
Gives me:
Binary file foo1 matches
Binary file foo2 matches
Binary file foo3 matches
To find the lines before/after, I then have to use the following on each file:
$ strings foo1 | grep -A1 -B1... (0 Replies)
Discussion started by: chipperuga
0 Replies
10. Shell Programming and Scripting
Hi guys,
I need to know how i can ignore Pipe '|' if Pipe is coming as a column in Pipe delimited file
for eg:
file 1:
xx|yy|"xyz|zzz"|zzz|12...
using below awk command
awk 'BEGIN {FS=OFS="|" } print $3
i would get xyz
But i want as :
xyz|zzz to consider as whole column... (13 Replies)
Discussion started by: rohit_shinez
13 Replies
LEARN ABOUT DEBIAN
io_pipe
io_pipe(3) Library Functions Manual io_pipe(3)
NAME
io_pipe - create a Unix pipe
SYNTAX
#include <io.h>
int io_pipe(int64 pfd[2]);
DESCRIPTION
io_pipe creates a new UNIX ``pipe.'' The pipe can receive data and provide data; any bytes written to the pipe can then be read from the
pipe in the same order.
A pipe is typically stored in an 8192-byte memory buffer; the exact number depends on the UNIX kernel. Bytes are written to the end of the
buffer and read from the beginning of the buffer. Once a byte has been read, it is eliminated from the buffer, making space for another
byte to be written; readers cannot ``rewind'' a pipe to read old data. Once 8192 bytes have been written to the buffer, the pipe will not
be ready for further writing until some of the bytes have been read. Once all the bytes written have been read, the pipe will not be ready
for further reading until more bytes are written.
io_pipe sets d[0] to the number of a new descriptor reading from the pipe, and sets d[1] to the number of a new descriptor writing to the
pipe. It then returns 1 to indicate success. If something goes wrong, io_pipe returns 0, setting errno to indicate the error; in this case
it frees any memory that it allocated for the new pipe, and it leaves d alone.
SEE ALSO
io_readfile(3), io_createfile(3), io_socketpair(3)
io_pipe(3)