Skip to content

Commit

Permalink
Traduction du chapitre sur les fonctions intervalle
Browse files Browse the repository at this point in the history
  • Loading branch information
gleu committed Oct 14, 2020
1 parent 3f129bc commit 6b08090
Showing 1 changed file with 57 additions and 51 deletions.
108 changes: 57 additions & 51 deletions postgresql/func.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18171,36 +18171,37 @@ SELECT NULLIF(value, '(none)') ...
</sect1>

<sect1 id="functions-range">
<title>Range Functions and Operators</title>
<title>Fonctions et opérateurs sur les intervalles</title>

<para>
See <xref linkend="rangetypes"/> for an overview of range types.
Voir <xref linkend="rangetypes"/> pour un aperçu les types d'intervalle.
</para>

<para>
<xref linkend="range-operators-table"/> shows the specialized operators
available for range types.
In addition to those, the usual comparison operators shown in
<xref linkend="functions-comparison-op-table"/> are available for range
types. The comparison operators order first by the range lower bounds, and
only if those are equal do they compare the upper bounds. This does not
usually result in a useful overall ordering, but the operators are provided
to allow unique indexes to be constructed on ranges.
<xref linkend="range-operators-table"/> montre les opérateurs spécialisés
disponibles pour les types d'intervalle. En plus de ces derniers, les
opérateurs de comparaison habituels montrés dans <xref
linkend="functions-comparison-op-table"/> sont disponibles pour les types
d'intervalle. Les opérateurs de comparaison trient d'abord par les limites
basses de l'intervalle et seulement si ces dernières sont identiques, par
les limites hautes. Ceci ne donne généralement pas de résultat utile pour
un tri, mais les opérateurs sont fournis pour autoriser la création d'index
d'unicité sur des intervalles.
</para>

<table id="range-operators-table">
<title>Range Operators</title>
<title>Opérateurs sur les intervalles</title>
<tgroup cols="1">
<thead>
<row>
<entry role="func_table_entry"><para role="func_signature">
Operator
Opérateur
</para>
<para>
Description
</para>
<para>
Example(s)
Exemple(s)
</para></entry>
</row>
</thead>
Expand All @@ -18212,7 +18213,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Does the first range contain the second?
Est-ce que le premier intervalle contient le second&nbsp;?
</para>
<para>
<literal>int4range(2,4) @&gt; int4range(2,3)</literal>
Expand All @@ -18226,7 +18227,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Does the range contain the element?
Est-ce que l'intervalle contient l'élément&nbsp;?
</para>
<para>
<literal>'[2011-01-01,2011-03-01)'::tsrange @&gt; '2011-01-10'::timestamp</literal>
Expand All @@ -18240,7 +18241,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the first range contained by the second?
Est-ce que le premier intervalle est contenu par le second&nbsp;?
</para>
<para>
<literal>int4range(2,4) &lt;@ int4range(1,7)</literal>
Expand All @@ -18254,7 +18255,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the element contained in the range?
Est-ce que l'élément est contenu dans l'intervalle&nbsp;?
</para>
<para>
<literal>42 &lt;@ int4range(1,7)</literal>
Expand All @@ -18268,7 +18269,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Do the ranges overlap, that is, have any elements in common?
Est-ce que les intervalles se surchargent, c'est-à-dire ont-ils des
éléments en commun&nbsp;?
</para>
<para>
<literal>int8range(3,7) &amp;&amp; int8range(4,12)</literal>
Expand All @@ -18282,7 +18284,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the first range strictly left of the second?
Est-ce que le premier intervalle se trouve strictement à gauche du
second&nbsp;?
</para>
<para>
<literal>int8range(1,10) &lt;&lt; int8range(100,110)</literal>
Expand All @@ -18296,7 +18299,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the first range strictly right of the second?
Est-ce que le premier intervalle se trouve strictement à droite du
second&nbsp;?
</para>
<para>
<literal>int8range(50,60) &gt;&gt; int8range(20,30)</literal>
Expand All @@ -18310,7 +18314,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Does the first range not extend to the right of the second?
Est-ce que le premier intervalle ne s'étend pas à droite du
second&nbsp;?
</para>
<para>
<literal>int8range(1,20) &amp;&lt; int8range(18,20)</literal>
Expand All @@ -18324,7 +18329,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Does the first range not extend to the left of the second?
Est-ce que le premier intervalle ne s'étend pas à gauche du
second&nbsp;?
</para>
<para>
<literal>int8range(7,20) &amp;&gt; int8range(5,10)</literal>
Expand All @@ -18338,7 +18344,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Are the ranges adjacent?
Les deux intervalles sont-ils adjacents&nbsp;?
</para>
<para>
<literal>numrange(1.1,2.2) -|- numrange(2.2,3.3)</literal>
Expand All @@ -18352,9 +18358,9 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>anyrange</returnvalue>
</para>
<para>
Computes the union of the ranges. The ranges must overlap or be
adjacent, so that the union is a single range (but
see <function>range_merge()</function>).
Calcule l'union des intervalles. Les intervalles doivent se surcharger
ou être adjacents, pour que l'union soit un intervalle simple
(cependant voir <function>range_merge()</function>).
</para>
<para>
<literal>numrange(5,15) + numrange(10,20)</literal>
Expand All @@ -18368,7 +18374,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>anyrange</returnvalue>
</para>
<para>
Computes the intersection of the ranges.
Calcule l'intersection des intervalles.
</para>
<para>
<literal>int8range(5,15) * int8range(10,20)</literal>
Expand All @@ -18382,9 +18388,9 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>anyrange</returnvalue>
</para>
<para>
Computes the difference of the ranges. The second range must not be
contained in the first in such a way that the difference would not be
a single range.
Calcule la différence des intervalles. Le deuxième intervalle ne doit
pas être contenu dans le premier de tel façon que la différence ne
formerait pas un intervalle simple.
</para>
<para>
<literal>int8range(5,15) - int8range(10,20)</literal>
Expand All @@ -18396,29 +18402,29 @@ SELECT NULLIF(value, '(none)') ...
</table>

<para>
The left-of/right-of/adjacent operators always return false when an empty
range is involved; that is, an empty range is not considered to be either
before or after any other range.
Les opérateurs gauche-de/droite-de/adjacent renvoient toujours false quand
un intervalle vide est impliqué&nbsp;; autrement dit, un intervalle vide
n'est pas considéré être avant ou après tout intervalle.
</para>

<para>
<xref linkend="range-functions-table"/> shows the functions
available for use with range types.
<xref linkend="range-functions-table"/> montre les fonctions disponibles
avec les types d'intervalle.
</para>

<table id="range-functions-table">
<title>Range Functions</title>
<title>Fonctions d'intervalle</title>
<tgroup cols="1">
<thead>
<row>
<entry role="func_table_entry"><para role="func_signature">
Function
Fonction
</para>
<para>
Description
</para>
<para>
Example(s)
Exemple(s)
</para></entry>
</row>
</thead>
Expand All @@ -18433,8 +18439,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>anyelement</returnvalue>
</para>
<para>
Extracts the lower bound of the range (<literal>NULL</literal> if the
range is empty or the lower bound is infinite).
Extrait la limite basse de l'intervalle (<literal>NULL</literal> si
l'intervalle est vide ou si la limite basse est infinie).
</para>
<para>
<literal>lower(numrange(1.1,2.2))</literal>
Expand All @@ -18451,8 +18457,8 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>anyelement</returnvalue>
</para>
<para>
Extracts the upper bound of the range (<literal>NULL</literal> if the
range is empty or the upper bound is infinite).
Extrait la limite haute de l'intervalle (<literal>NULL</literal> si
l'intervalle est vide ou si la limite haute est infinie).
</para>
<para>
<literal>upper(numrange(1.1,2.2))</literal>
Expand All @@ -18469,7 +18475,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the range empty?
Est-ce que l'intervalle est vide&nbsp;?
</para>
<para>
<literal>isempty(numrange(1.1,2.2))</literal>
Expand All @@ -18486,7 +18492,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the range's lower bound inclusive?
Est-ce que la limite basse de l'intervalle est inclus&nbsp;?
</para>
<para>
<literal>lower_inc(numrange(1.1,2.2))</literal>
Expand All @@ -18503,7 +18509,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the range's upper bound inclusive?
Est-ce que la limite haute de l'intervalle est inclus&nbsp;?
</para>
<para>
<literal>upper_inc(numrange(1.1,2.2))</literal>
Expand All @@ -18520,7 +18526,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the range's lower bound infinite?
Est-ce que la limite basse de l'intervalle est infinie&nbsp;?
</para>
<para>
<literal>lower_inf('(,)'::daterange)</literal>
Expand All @@ -18537,7 +18543,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>boolean</returnvalue>
</para>
<para>
Is the range's upper bound infinite?
Est-ce que la limite haute de l'intervalle est infinie&nbsp;?
</para>
<para>
<literal>upper_inf('(,)'::daterange)</literal>
Expand All @@ -18554,7 +18560,7 @@ SELECT NULLIF(value, '(none)') ...
<returnvalue>anyrange</returnvalue>
</para>
<para>
Computes the smallest range that includes both of the given ranges.
Calcule le plus petit intervalle incluant les deux intervalles.
</para>
<para>
<literal>range_merge('[1,2)'::int4range, '[3,4)'::int4range)</literal>
Expand All @@ -18566,9 +18572,9 @@ SELECT NULLIF(value, '(none)') ...
</table>

<para>
The <function>lower_inc</function>, <function>upper_inc</function>,
<function>lower_inf</function>, and <function>upper_inf</function>
functions all return false for an empty range.
Les fonctions <function>lower_inc</function>, <function>upper_inc</function>,
<function>lower_inf</function> et <function>upper_inf</function>
renvoient toutes false pour un intervalle vide.
</para>
</sect1>

Expand Down

0 comments on commit 6b08090

Please sign in to comment.