Re: popcount
David Fetter <david@fetter.org>
From: David Fetter <david@fetter.org>
To: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
Cc: Daniel Verite <daniel@manitou-mail.org>, PostgreSQL Development <pgsql-hackers@postgresql.org>, Vik Fearing <vik.fearing@2ndquadrant.com>
Date: 2021-01-11T16:13:54Z
Lists: pgsql-hackers
Attachments
- v3-0001-popcount.patch (text/x-diff)
On Mon, Jan 11, 2021 at 03:50:54PM +0100, Peter Eisentraut wrote: > On 2020-12-30 17:41, David Fetter wrote: > > > The input may have more than 2 billion bits set to 1. The biggest possible > > > result should be 8 billion for bytea (1 GB with all bits set to 1). > > > So shouldn't this function return an int8? > > It does now, and thanks for looking at this. > > The documentation still reflects the previous int4 return type (in two > different spellings, too). Thanks for looking this over! Please find attached the next version with corrected documentation. Best, David. -- David Fetter <david(at)fetter(dot)org> http://fetter.org/ Phone: +1 415 235 3778 Remember to vote! Consider donating to Postgres: http://www.postgresql.org/about/donate
Commits
-
Add bit_count SQL function
- a6715af1e72d 14.0 landed