On Wed, 13 Feb 2019, Andrew Gierth wrote:
> Rich> Will probably try DISTINCT ON, too, if that makes it simpler or> Rich> faster.>> You want LATERAL.
Andrew,
That's new to me so I'll read about it.
Thanks,
Rich