From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 64196 invoked by alias); 22 Jul 2019 19:50:54 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 64187 invoked by uid 89); 22 Jul 2019 19:50:54 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=0.5 required=5.0 tests=AWL,BAYES_50,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.1 spammy=H*UA:16.0, H*x:16.0, HX-Languages-Length:664, H*UA:Outlook X-HELO: resqmta-po-12v.sys.comcast.net Received: from resqmta-po-12v.sys.comcast.net (HELO resqmta-po-12v.sys.comcast.net) (96.114.154.171) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 22 Jul 2019 19:50:53 +0000 Received: from resomta-po-06v.sys.comcast.net ([96.114.154.230]) by resqmta-po-12v.sys.comcast.net with ESMTP id pdFAh0Jh1TbnXpeKhhd7Ec; Mon, 22 Jul 2019 19:50:51 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=20190202a; t=1563825051; bh=/K0ZAI7yfI1Qur5vTT/DVrJJ+9kgCcrFhAFTRHEHIO8=; h=Received:Received:From:To:Subject:Date:Message-ID:MIME-Version: Content-Type; b=KSUhup4ksnuw7TTrw5MFmsuB/3gXkFC4Icwy2kLPpq7sGxspeXWqDS9w/ioPk+07A ML1sjCPS6147fmWATooO4/oU0pl8Yn/q8zf+nOLb16IhylCJpjnBx0rmXqdmhCeEVT 9viJiiQr8sYkxub6FBAYUvWiEqPWhTDR3BxSxhEjX8h0KDG8FOVZgEuYHxd6aQSSng QwwQPseRhyllF6Ef5tdGeMsUjkiSDr+Scym3AF6ZY3otiy/1qNAoXHYSM38uBmU3yM fUYsg/+HMq5xxsgaiI2j/81N0XxbF15PHDc+6+5arNjEzLxv0PU21XXufIrA9m1qNS 4xVQ39FX/8BWg== Received: from AndyWork ([73.223.74.29]) by resomta-po-06v.sys.comcast.net with ESMTPA id peKghIVVFGOcqpeKghoXWM; Mon, 22 Jul 2019 19:50:51 +0000 X-Xfinity-VAAS: gggruggvucftvghtrhhoucdtuddrgeduvddrjeeggddugeehucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuvehomhgtrghsthdqtfgvshhipdfqfgfvpdfpqffurfetoffkrfenuceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkgggtgffothesthejghdtvddtvdenucfhrhhomhepfdetnhguhicujfgrlhhlfdcuoehfihigphgvrhhtihhsvgdqtghonhhsuhhlthhinhhgsegtohhmtggrshhtrdhnvghtqeenucfkphepjeefrddvvdefrdejgedrvdelnecurfgrrhgrmhephhgvlhhopeetnhguhighohhrkhdpihhnvghtpeejfedrvddvfedrjeegrddvledpmhgrihhlfhhrohhmpehfihigphgvrhhtihhsvgdqtghonhhsuhhlthhinhhgsegtohhmtggrshhtrdhnvghtpdhrtghpthhtoheptgihghifihhnsegthihgfihinhdrtghomhenucevlhhushhtvghrufhiiigvpedt X-Xfinity-VMeta: sc=0;st=legit From: "Andy Hall" To: Subject: Join command fails to output fields on input file with DOS line endings. Date: Mon, 22 Jul 2019 19:50:00 -0000 Message-ID: <009e01d540c6$c1b11d50$451357f0$@comcast.net> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2019-07/txt/msg00171.txt.bz2 This behavior of join surprised me: $ join -1 3 <(echo a b col3 c d | unix2dos) <(echo col3 f2 f3 f4 f5) f2 f3 f4 f5 Join parses the input line well enough to execute the join, but the presence of the DOS line endings suppresses the output of fields from the first input. Compare with $ join -1 3 <(echo a b col3 c d) <(echo col3 f2 f3 f4 f5) col3 a b c d f2 f3 f4 f5 which is correct. Here is a weirder example where the join field is missing and the output is reversed! NOK $ join <(echo col F1 | unix2dos) <(echo col F2) F2 F1 OK $ join <(echo col F1) <(echo col F2) col F1 F2 -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple