GNU bug report logs - #10924
Updated patch for Bug #6366

Previous Next

Package: coreutils;

Reported by: Drew Frank <drewfrank <at> gmail.com>

Date: Fri, 2 Mar 2012 07:21:02 UTC

Severity: wishlist

Tags: patch

Merged with 6366, 12264

Full log


Message #11 received at 10924 <at> debbugs.gnu.org (full text, mbox):

From: Eric Blake <eblake <at> redhat.com>
To: Drew Frank <drewfrank <at> gmail.com>
Cc: 10924 <at> debbugs.gnu.org
Subject: Re: bug#10924: Updated patch for Bug #6366
Date: Wed, 21 Mar 2012 10:59:21 -0600
[Message part 1 (text/plain, inline)]
On 03/01/2012 09:05 PM, Drew Frank wrote:
> Hi,
> 
> Bug #6366 was reported over a year ago to address a deficiency in "join":
> it is unable to join on fields that are sorted numerically (rather than
> lexicographically). The bug report has a patch attached -- I applied it to
> the current Git head, cleaned up a few things, and added a couple tests.
> 
> In response to previous discussions on the issue, my two cents:
> * "sort" includes several other sorting criteria, but they're not likely to
> be useful in this context.
> * This patch doesn't implement the functionality of sort's "-g" option, so
> "-n" is appropriate.
> * If two values have different string representations but compare as equal
> due to lack of precision...well, the person doing the join should be aware
> of the limits of floating point representations and use the "sort, join,
> sort -n" strategy. I doubt this would come up much in practice though.
> 
> The lack of this option seems like an unusually conspicuous wart and I'd
> love to see it addressed. Please let me know if I can be of any more help
> to that effect.
> 
> Best,
> Drew Frank

> * src/join.c: add new flags and implement numeric comparison feature.
> * tests/misc/join: add two tests for numerically sorted key fields.
> This patch is based on code written by Alex Shinn
> <Alex Shinn <at> gmail.com>
> ---
>  src/join.c      |   22 +++++++++++++++++++---
>  tests/misc/join |    6 ++++++
>  2 files changed, 25 insertions(+), 3 deletions(-)

Missing documentation in NEWS and doc/coreutils.texi.

Based on just the diffstat, this patch is non-trivial, so we'd need
copyright assignment to the FSF from both you and from Alex Shinn, as
co-authors of this material.  Is that something you are interested in
pursuing?  I'm refraining from reviewing the patch itself, in case we
need to come up with a clean-room reimplementation.

-- 
Eric Blake   eblake <at> redhat.com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

[signature.asc (application/pgp-signature, attachment)]

This bug report was last modified 6 years and 260 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.