coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: feature request: self join from stdin


From: Bernhard Voelker
Subject: Re: feature request: self join from stdin
Date: Sun, 20 Oct 2019 19:33:34 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.0

On 2018-11-25 17:45, address@hidden wrote:
> Please consider a self join from stdin in coreutils.
> 
> $ seq 3 | join -j2 - - | paste -s
>  1 1   1 2     1 3     2 1     2 2     2 3     3 1     3 2     3 3

What about tee'ing into a 'fifo' which is read again by join?

 $ mkfifo fifo \
     && seq 3 | tee fifo | join -j2 - fifo | paste -s \
     && rm fifo
 1 1     1 2     1 3     2 1     2 2     2 3     3 1     3 2     3 3

Have a nice day,
Berny



reply via email to

[Prev in Thread] Current Thread [Next in Thread]