Re: range data type size not mention in docs.

2022-02-16 Thread David G. Johnston
On Wednesday, February 16, 2022, Jian He wrote: > > range type seem not mention their size in the docs. > multi range size is variable. > But range size seems fixed. > why it's 17 byte? > > select pg_column_size('[10,20)' ::int4range ); --17 byte > select pg_column_size('[-2147483648,2147483647

range data type size not mention in docs.

2022-02-16 Thread Jian He
range type seem not mention their size in the docs. multi range size is variable. But range size seems fixed. why it's 17 byte? select pg_column_size('[10,20)' ::int4range ); --17 byte select pg_column_size('[-2147483648,2147483647)' ::int4range ); --17 byte.

Re: Does the POSITION() function takes into account the COLLATION... or not ?!?

2022-02-16 Thread Pierre-Aurélien GEORGES
ok, let's take it forwards, then :-) Can someone provide some examples where a supported deterministic collation is having an impact on the result of a call to function POSITION() ? (as I said in my message, examples would be greatly appreciated) Le 16/02/2022 à 11:56, Peter Eisentraut a éc

Re: Does the POSITION() function takes into account the COLLATION... or not ?!?

2022-02-16 Thread Tom Lane
"David G. Johnston" writes: > On Tue, Feb 15, 2022 at 11:17 AM PG Doc comments form < > nore...@postgresql.org> wrote: >> ==> up to here, this seems pretty enough to conclude that POSITION() >> doesn't >> care at all about COLLATION and always perform a byte search. > How collations behave is doc

Re: Does the POSITION() function takes into account the COLLATION... or not ?!?

2022-02-16 Thread David G. Johnston
On Tue, Feb 15, 2022 at 11:17 AM PG Doc comments form < nore...@postgresql.org> wrote: > The following documentation comment has been logged on the website: > > Page: https://www.postgresql.org/docs/14/functions-string.html > Description: > > > SELECT POSITION(('å' COLLATE "en_US.utf8") IN 'yeah')

Re: Does the POSITION() function takes into account the COLLATION... or not ?!?

2022-02-16 Thread Peter Eisentraut
On Wed, Feb 16, 2022 at 12:01 PM Pierre-Aurélien GEORGES < pierre-aurelien.geor...@univ-cotedazur.fr> wrote: > ok, let's take it forwards, then :-) > > Can someone provide some examples where a supported deterministic > collation is having an impact on the result of a call to function > POSITION()

Re: Does the POSITION() function takes into account the COLLATION... or not ?!?

2022-02-16 Thread Peter Eisentraut
On 15.02.22 17:17, PG Doc comments form wrote: Does the POSITION() function pretends taking into account the COLLATION ?? or not ?? - If not, then why the hell is there this error message about nondeterministic collations while the POSITION() doesn't care at all about the COLLATION... - If yes,