Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 7539a1b

Browse files
committed
doc: clarify handling of range upper/lower/upper_inf/lower_inf()
Clarify handling of infinite range bounds. Reported-by: jani.rahkola@iki.fi Discussion: https://postgr.es/m/160508672127.25505.8356390205508789564@wrigleys.postgresql.org Co-authored-by: Laurenz Albe Backpatch-through: 16
1 parent d1379eb commit 7539a1b

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

doc/src/sgml/func.sgml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19963,7 +19963,7 @@ SELECT NULLIF(value, '(none)') ...
1996319963
</para>
1996419964
<para>
1996519965
Extracts the lower bound of the range (<literal>NULL</literal> if the
19966-
range is empty or the lower bound is infinite).
19966+
range is empty or has no lower bound).
1996719967
</para>
1996819968
<para>
1996919969
<literal>lower(numrange(1.1,2.2))</literal>
@@ -19981,7 +19981,7 @@ SELECT NULLIF(value, '(none)') ...
1998119981
</para>
1998219982
<para>
1998319983
Extracts the upper bound of the range (<literal>NULL</literal> if the
19984-
range is empty or the upper bound is infinite).
19984+
range is empty or has no upper bound).
1998519985
</para>
1998619986
<para>
1998719987
<literal>upper(numrange(1.1,2.2))</literal>
@@ -20049,7 +20049,8 @@ SELECT NULLIF(value, '(none)') ...
2004920049
<returnvalue>boolean</returnvalue>
2005020050
</para>
2005120051
<para>
20052-
Is the range's lower bound infinite?
20052+
Does the range have no lower bound? (A lower bound of
20053+
<literal>-Infinity</literal> returns false.)
2005320054
</para>
2005420055
<para>
2005520056
<literal>lower_inf('(,)'::daterange)</literal>
@@ -20066,7 +20067,8 @@ SELECT NULLIF(value, '(none)') ...
2006620067
<returnvalue>boolean</returnvalue>
2006720068
</para>
2006820069
<para>
20069-
Is the range's upper bound infinite?
20070+
Does the range have no upper bound? (An upper bound of
20071+
<literal>Infinity</literal> returns false.)
2007020072
</para>
2007120073
<para>
2007220074
<literal>upper_inf('(,)'::daterange)</literal>
@@ -20121,7 +20123,7 @@ SELECT NULLIF(value, '(none)') ...
2012120123
</para>
2012220124
<para>
2012320125
Extracts the lower bound of the multirange (<literal>NULL</literal> if the
20124-
multirange is empty or the lower bound is infinite).
20126+
multirange is empty has no lower bound).
2012520127
</para>
2012620128
<para>
2012720129
<literal>lower('{[1.1,2.2)}'::nummultirange)</literal>
@@ -20139,7 +20141,7 @@ SELECT NULLIF(value, '(none)') ...
2013920141
</para>
2014020142
<para>
2014120143
Extracts the upper bound of the multirange (<literal>NULL</literal> if the
20142-
multirange is empty or the upper bound is infinite).
20144+
multirange is empty or has no upper bound).
2014320145
</para>
2014420146
<para>
2014520147
<literal>upper('{[1.1,2.2)}'::nummultirange)</literal>
@@ -20207,7 +20209,8 @@ SELECT NULLIF(value, '(none)') ...
2020720209
<returnvalue>boolean</returnvalue>
2020820210
</para>
2020920211
<para>
20210-
Is the multirange's lower bound infinite?
20212+
Does the multirange have no lower bound? (A lower bound of
20213+
<literal>-Infinity</literal> returns false.)
2021120214
</para>
2021220215
<para>
2021320216
<literal>lower_inf('{(,)}'::datemultirange)</literal>
@@ -20224,7 +20227,8 @@ SELECT NULLIF(value, '(none)') ...
2022420227
<returnvalue>boolean</returnvalue>
2022520228
</para>
2022620229
<para>
20227-
Is the multirange's upper bound infinite?
20230+
Does the multirange have no upper bound? (An upper bound of
20231+
<literal>Infinity</literal> returns false.)
2022820232
</para>
2022920233
<para>
2023020234
<literal>upper_inf('{(,)}'::datemultirange)</literal>

0 commit comments

Comments
 (0)