Thanks for the report.
I believe this is not a bug in sort.

This misunderstanding may be due to a weakness in the documentation.
The way sort's -b modifier works is different from the way any of the other
modifiers work in that it means different things when applied to the
field-start than when applied to the field-end part of the key specifier.
Or perhaps it's due to the ambiguity of whether those blanks are at the
end of the first field or at the beginning of the second one.

To get the behavior you want, either apply `b' to the field-end
specifier of the first key,

         % sort +0b -1b +2b -3

or simply use the global -b option:

         % sort -b +0 -1 +2 -3

Shigio Yamaguchi <[EMAIL PROTECTED]> writes:
| Hello,
|
| I think I have found a bug in sort.
|
| Sort(1) is effected by blanks around skipped column.
|
| For example,
|
|         % sort +0b -1 +2b -3
|         A A B
|         A  A A
|         ^D
|
| should be sorted as follows.
|
|         A  A A
|         A A B
|
| But the result is this.
|
|         A A B
|         A  A A
|
| If you make these columns even like this, it works well.
|
|         A A B
|         A A A

Reply via email to