percentile value check can be slow - Mailing list pgsql-hackers

From jotpe
Subject percentile value check can be slow
Date
Msg-id 3f60fe5f-6df0-d889-ebad-def2dcb4db57@posteo.de
Whole thread Raw
Responses Re: percentile value check can be slow  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
I tried to enter invalid percentile fractions, and was astonished that 
it seems to be checked after many work is done?

psql (11devel)
Type "help" for help.

jotpe=# \timing
Timing is on.
jotpe=# select percentile_cont(array[0,0.25,0.5,1,1,null,2]) within 
group(order by txk) from klima_tag;
ERROR:  percentile value 2 is not between 0 and 1
Time: 19155,565 ms (00:19,156)
jotpe=# select count(*) from klima_tag;  count
---------- 13950214
(1 row)

Time: 933,847 ms


Best regards Johannes


pgsql-hackers by date:

Previous
From: 高增琦
Date:
Subject: Re: no library dependency in Makefile?
Next
From: Michael Paquier
Date:
Subject: Re: [JDBC] [HACKERS] Channel binding support for SCRAM-SHA-256