bug-obsolete-packages
[Top][All Lists]
Advanced

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

[bug-obsolete-packages] join: A problem with TAB output separator in cmd


From: Stanislav Pronkin
Subject: [bug-obsolete-packages] join: A problem with TAB output separator in cmd.exe
Date: Tue, 8 Nov 2016 23:59:24 +0300

Hello!

C:\nncron>join --version
join (GNU textutils) 2.0
Written by Mike Haertel.

Copyright (C) 1999 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\nncron>cat A.txt
John    A       1
Linda   B       2
Rares   C       3
Lubos   D       4
Rick    I       4

C:\nncron>cat B.txt
John    E       1
Linda   F       2
Rares   G       3
Lubos   H       4
Andrey  J       7

C:\nncron>join.exe -j 1 -a2 A.txt B.txt
John A 1 E 1
Linda B 2 F 2
Rares C 3 G 3
Lubos D 4 H 4
Andrey J 7

If I use TAB CHAR as input and output field separator

then it does not work correctly:
C:\nncron>join.exe -j 1 -a2 -t "\t" A.txt B.txt
John    E       1
Linda   F       2
Rares   G       3
Lubos   H       4
Andrey  J       7

C:\nncron>join.exe -j 1 -a2 -t "\\t" A.txt B.txt
John    E       1
Linda   F       2
Rares   G       3
Lubos   H       4
Andrey  J       7

C:\nncron>join.exe -j 1 -a2 -t\t A.txt B.txt
John    E       1
Linda   F       2
Rares   G       3
Lubos   H       4
Andrey  J       7

C:\nncron>join.exe -j 1 -a2 -t\x09 A.txt B.txt
John    E       1
Linda   F       2
Rares   G       3
Lubos   H       4
Andrey  J       7

C:\nncron>join.exe -j 1 -a2 -t"\x09" A.txt B.txt
John    E       1
Linda   F       2
Rares   G       3
Lubos   H       4
Andrey  J       7

If I use GNU bash version 4.4.0(1)-release (x86_64-apple-darwin14.5.0), then this is work:

bash$ join -t $'\t' A.txt B.txt
John      A    1    E    1
Linda     B    2    F    2
Rares     C    3    G    3
Lubos     D    4    H    4
Andrey    J    7

Why is this happening? Maybe it's not a bug, and I did something wrong? Explain to me how to do it. Help!

reply via email to

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