| 1 |
<?xml version="1.0" encoding="ISO-8859-15"?> |
|---|
| 2 |
<!-- Dernière modification |
|---|
| 3 |
le $Date$ |
|---|
| 4 |
par $Author$ |
|---|
| 5 |
révision $Revision$ --> |
|---|
| 6 |
<!-- |
|---|
| 7 |
Documentation of the system catalogs, directed toward PostgreSQL developers |
|---|
| 8 |
--> |
|---|
| 9 |
<!-- SAS : 20070314 --> |
|---|
| 10 |
|
|---|
| 11 |
<chapter id="catalogs"> |
|---|
| 12 |
<title>Catalogues système</title> |
|---|
| 13 |
|
|---|
| 14 |
<para> |
|---|
| 15 |
Les catalogues système représentent l'endroit où une base de données relationnelle |
|---|
| 16 |
stocke les métadonnées des schémas, telles que les informations sur les tables |
|---|
| 17 |
et les colonnes, et des données de suivi interne. |
|---|
| 18 |
Les catalogues système de <productname>PostgreSQL</productname> sont de |
|---|
| 19 |
simples tables. Elle peuvent être supprimées et recrées. Il est possible |
|---|
| 20 |
de leur ajouter des colonnes, d'y insérer et modifier des valeurs, et de |
|---|
| 21 |
mettre un joyeux bazar dans le système. En temps normal, l'utilisateur n'a aucune |
|---|
| 22 |
raison de modifier les catalogues |
|---|
| 23 |
système, il y a toujours des commandes SQL pour le faire. (Par |
|---|
| 24 |
exemple, <command>CREATE DATABASE</command> insère une ligne dans le |
|---|
| 25 |
catalogue <structname>pg_database</structname> — et crée physiquement |
|---|
| 26 |
la base de données sur le disque.) Il y a des exceptions pour certaines |
|---|
| 27 |
opérations particulièrement ésotériques, comme l'ajout de méthodes d'accès |
|---|
| 28 |
aux index. |
|---|
| 29 |
</para> |
|---|
| 30 |
|
|---|
| 31 |
<sect1 id="catalogs-overview"> |
|---|
| 32 |
<title>Aperçu</title> |
|---|
| 33 |
|
|---|
| 34 |
<para> |
|---|
| 35 |
<xref linkend="catalog-table"/> liste les catalogues système. |
|---|
| 36 |
Une documentation plus détaillée des catalogues système suit. |
|---|
| 37 |
</para> |
|---|
| 38 |
|
|---|
| 39 |
<para> |
|---|
| 40 |
La plupart des catalogues système sont recopiés de la base de données modèle |
|---|
| 41 |
lors de la création de la base de données et deviennent alors spécifiques à |
|---|
| 42 |
chaque base de données. Un petit nombre de catalogues sont physiquement |
|---|
| 43 |
partagés par toutes les bases de données d'une installation de |
|---|
| 44 |
<productname>PostgreSQL</productname>. Ils sont indiqués dans les |
|---|
| 45 |
descriptions des catalogues. |
|---|
| 46 |
</para> |
|---|
| 47 |
|
|---|
| 48 |
<table id="catalog-table"> |
|---|
| 49 |
<title>Catalogues système</title> |
|---|
| 50 |
|
|---|
| 51 |
<tgroup cols="2"> |
|---|
| 52 |
<colspec colnum="1" colwidth="1*"/> |
|---|
| 53 |
<colspec colnum="2" colwidth="2*"/> |
|---|
| 54 |
<thead> |
|---|
| 55 |
<row> |
|---|
| 56 |
<entry>Nom du catalogue</entry> |
|---|
| 57 |
<entry>Contenu</entry> |
|---|
| 58 |
</row> |
|---|
| 59 |
</thead> |
|---|
| 60 |
|
|---|
| 61 |
<tbody> |
|---|
| 62 |
<row> |
|---|
| 63 |
<entry><link linkend="catalog-pg-aggregate"><structname>pg_aggregate</structname></link></entry> |
|---|
| 64 |
<entry>fonctions d'agrégat</entry> |
|---|
| 65 |
</row> |
|---|
| 66 |
|
|---|
| 67 |
<row> |
|---|
| 68 |
<entry><link linkend="catalog-pg-am"><structname>pg_am</structname></link></entry> |
|---|
| 69 |
<entry>méthodes d'accès aux index</entry> |
|---|
| 70 |
</row> |
|---|
| 71 |
|
|---|
| 72 |
<row> |
|---|
| 73 |
<entry><link linkend="catalog-pg-amop"><structname>pg_amop</structname></link></entry> |
|---|
| 74 |
<entry>opérateurs des méthodes d'accès</entry> |
|---|
| 75 |
</row> |
|---|
| 76 |
|
|---|
| 77 |
<row> |
|---|
| 78 |
<entry><link linkend="catalog-pg-amproc"><structname>pg_amproc</structname></link></entry> |
|---|
| 79 |
<entry>procédures de support des méthodes d'accès</entry> |
|---|
| 80 |
</row> |
|---|
| 81 |
|
|---|
| 82 |
<row> |
|---|
| 83 |
<entry><link linkend="catalog-pg-attrdef"><structname>pg_attrdef</structname></link></entry> |
|---|
| 84 |
<entry>valeurs par défaut des colonnes</entry> |
|---|
| 85 |
</row> |
|---|
| 86 |
|
|---|
| 87 |
<row> |
|---|
| 88 |
<entry><link linkend="catalog-pg-attribute"><structname>pg_attribute</structname></link></entry> |
|---|
| 89 |
<entry>colonnes des tables (<quote>attributs</quote>)</entry> |
|---|
| 90 |
</row> |
|---|
| 91 |
|
|---|
| 92 |
<row> |
|---|
| 93 |
<entry><link linkend="catalog-pg-authid"><structname>pg_authid</structname></link></entry> |
|---|
| 94 |
<entry>identifiants d'autorisation (rôles)</entry> |
|---|
| 95 |
</row> |
|---|
| 96 |
|
|---|
| 97 |
<row> |
|---|
| 98 |
<entry><link linkend="catalog-pg-auth-members"><structname>pg_auth_members</structname></link></entry> |
|---|
| 99 |
<entry>relations d'appartenance aux identifiants d'autorisation</entry> |
|---|
| 100 |
</row> |
|---|
| 101 |
|
|---|
| 102 |
<row> |
|---|
| 103 |
<entry><link linkend="catalog-pg-autovacuum"><structname>pg_autovacuum</structname></link></entry> |
|---|
| 104 |
<entry>paramètres de configuration de l'autovacuum par relation</entry> |
|---|
| 105 |
</row> |
|---|
| 106 |
|
|---|
| 107 |
<row> |
|---|
| 108 |
<entry><link linkend="catalog-pg-cast"><structname>pg_cast</structname></link></entry> |
|---|
| 109 |
<entry>conversions de types de données (<foreignphrase>cast</foreignphrase>)</entry> |
|---|
| 110 |
</row> |
|---|
| 111 |
|
|---|
| 112 |
<row> |
|---|
| 113 |
<entry><link linkend="catalog-pg-class"><structname>pg_class</structname></link></entry> |
|---|
| 114 |
<entry>tables, index, séquences, vues (<quote>relations</quote>)</entry> |
|---|
| 115 |
</row> |
|---|
| 116 |
|
|---|
| 117 |
<row> |
|---|
| 118 |
<entry><link linkend="catalog-pg-constraint"><structname>pg_constraint</structname></link></entry> |
|---|
| 119 |
<entry>contraintes de vérification, contraintes uniques, contraintes de clés primaires, contraintes de clés étrangères</entry> |
|---|
| 120 |
</row> |
|---|
| 121 |
|
|---|
| 122 |
<row> |
|---|
| 123 |
<entry><link linkend="catalog-pg-conversion"><structname>pg_conversion</structname></link></entry> |
|---|
| 124 |
<entry>informations de conversions de codage</entry> |
|---|
| 125 |
</row> |
|---|
| 126 |
|
|---|
| 127 |
<row> |
|---|
| 128 |
<entry><link linkend="catalog-pg-database"><structname>pg_database</structname></link></entry> |
|---|
| 129 |
<entry>bases de données du cluster <productname>PostgreSQL</productname></entry> |
|---|
| 130 |
</row> |
|---|
| 131 |
|
|---|
| 132 |
<row> |
|---|
| 133 |
<entry><link linkend="catalog-pg-depend"><structname>pg_depend</structname></link></entry> |
|---|
| 134 |
<entry>dépendances entre objets de la base de données</entry> |
|---|
| 135 |
</row> |
|---|
| 136 |
|
|---|
| 137 |
<row> |
|---|
| 138 |
<entry><link linkend="catalog-pg-description"><structname>pg_description</structname></link></entry> |
|---|
| 139 |
<entry>descriptions ou commentaires des objets de base de données</entry> |
|---|
| 140 |
</row> |
|---|
| 141 |
|
|---|
| 142 |
<row> |
|---|
| 143 |
<entry><link linkend="catalog-pg-enum"><structname>pg_enum</structname></link></entry> |
|---|
| 144 |
<entry>définitions des labels et des valeurs des enum</entry> |
|---|
| 145 |
</row> |
|---|
| 146 |
|
|---|
| 147 |
<row> |
|---|
| 148 |
<entry><link linkend="catalog-pg-index"><structname>pg_index</structname></link></entry> |
|---|
| 149 |
<entry>informations supplémentaires des index</entry> |
|---|
| 150 |
</row> |
|---|
| 151 |
|
|---|
| 152 |
<row> |
|---|
| 153 |
<entry><link linkend="catalog-pg-inherits"><structname>pg_inherits</structname></link></entry> |
|---|
| 154 |
<entry>hiérarchie d'héritage de tables</entry> |
|---|
| 155 |
</row> |
|---|
| 156 |
|
|---|
| 157 |
<row> |
|---|
| 158 |
<entry><link linkend="catalog-pg-language"><structname>pg_language</structname></link></entry> |
|---|
| 159 |
<entry>langages d'écriture de fonctions</entry> |
|---|
| 160 |
</row> |
|---|
| 161 |
|
|---|
| 162 |
<row> |
|---|
| 163 |
<entry><link linkend="catalog-pg-largeobject"><structname>pg_largeobject</structname></link></entry> |
|---|
| 164 |
<entry>gros objets</entry> |
|---|
| 165 |
</row> |
|---|
| 166 |
|
|---|
| 167 |
<row> |
|---|
| 168 |
<entry><link linkend="catalog-pg-listener"><structname>pg_listener</structname></link></entry> |
|---|
| 169 |
<entry>support de notification asynchrone</entry> |
|---|
| 170 |
</row> |
|---|
| 171 |
|
|---|
| 172 |
<row> |
|---|
| 173 |
<entry><link linkend="catalog-pg-namespace"><structname>pg_namespace</structname></link></entry> |
|---|
| 174 |
<entry>schémas</entry> |
|---|
| 175 |
</row> |
|---|
| 176 |
|
|---|
| 177 |
<row> |
|---|
| 178 |
<entry><link linkend="catalog-pg-opclass"><structname>pg_opclass</structname></link></entry> |
|---|
| 179 |
<entry>classes d'opérateurs de méthodes d'accès</entry> |
|---|
| 180 |
</row> |
|---|
| 181 |
|
|---|
| 182 |
<row> |
|---|
| 183 |
<entry><link linkend="catalog-pg-operator"><structname>pg_operator</structname></link></entry> |
|---|
| 184 |
<entry>opérateurs</entry> |
|---|
| 185 |
</row> |
|---|
| 186 |
|
|---|
| 187 |
<row> |
|---|
| 188 |
<entry><link linkend="catalog-pg-opfamily"><structname>pg_opfamily</structname></link></entry> |
|---|
| 189 |
<entry>familles d'opérateurs de méthodes d'accès</entry> |
|---|
| 190 |
</row> |
|---|
| 191 |
|
|---|
| 192 |
<row> |
|---|
| 193 |
<entry><link linkend="catalog-pg-pltemplate"><structname>pg_pltemplate</structname></link></entry> |
|---|
| 194 |
<entry>données modèles pour les langages procéduraux</entry> |
|---|
| 195 |
</row> |
|---|
| 196 |
|
|---|
| 197 |
<row> |
|---|
| 198 |
<entry><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link></entry> |
|---|
| 199 |
<entry>fonctions et procédures</entry> |
|---|
| 200 |
</row> |
|---|
| 201 |
|
|---|
| 202 |
<row> |
|---|
| 203 |
<entry><link linkend="catalog-pg-rewrite"><structname>pg_rewrite</structname></link></entry> |
|---|
| 204 |
<entry>règles de réécriture de requêtes</entry> |
|---|
| 205 |
</row> |
|---|
| 206 |
|
|---|
| 207 |
<row> |
|---|
| 208 |
<entry><link linkend="catalog-pg-shdepend"><structname>pg_shdepend</structname></link></entry> |
|---|
| 209 |
<entry>dépendances sur les objets partagés</entry> |
|---|
| 210 |
</row> |
|---|
| 211 |
|
|---|
| 212 |
<row> |
|---|
| 213 |
<entry><link linkend="catalog-pg-shdescription"><structname>pg_shdescription</structname></link></entry> |
|---|
| 214 |
<entry>commentaires sur les objets partagés</entry> |
|---|
| 215 |
</row> |
|---|
| 216 |
|
|---|
| 217 |
<row> |
|---|
| 218 |
<entry><link linkend="catalog-pg-statistic"><structname>pg_statistic</structname></link></entry> |
|---|
| 219 |
<entry>statistiques de l'optimiseur de requêtes</entry> |
|---|
| 220 |
</row> |
|---|
| 221 |
|
|---|
| 222 |
<row> |
|---|
| 223 |
<entry><link linkend="catalog-pg-tablespace"><structname>pg_tablespace</structname></link></entry> |
|---|
| 224 |
<entry><foreignphrase>tablespaces</foreignphrase> du cluster de bases de données</entry> |
|---|
| 225 |
</row> |
|---|
| 226 |
|
|---|
| 227 |
<row> |
|---|
| 228 |
<entry><link linkend="catalog-pg-trigger"><structname>pg_trigger</structname></link></entry> |
|---|
| 229 |
<entry>déclencheurs</entry> |
|---|
| 230 |
</row> |
|---|
| 231 |
|
|---|
| 232 |
<row> |
|---|
| 233 |
<entry><link linkend="catalog-pg-ts-config"><structname>pg_ts_config</structname></link></entry> |
|---|
| 234 |
<entry>configuration de la recherche plein texte</entry> |
|---|
| 235 |
</row> |
|---|
| 236 |
|
|---|
| 237 |
<row> |
|---|
| 238 |
<entry><link linkend="catalog-pg-ts-config-map"><structname>pg_ts_config_map</structname></link></entry> |
|---|
| 239 |
<entry>configuration de la recherche plein texte pour la correspondance |
|---|
| 240 |
des lexèmes (<foreignphrase>token</foreignphrase>)</entry> |
|---|
| 241 |
</row> |
|---|
| 242 |
|
|---|
| 243 |
<row> |
|---|
| 244 |
<entry><link linkend="catalog-pg-ts-dict"><structname>pg_ts_dict</structname></link></entry> |
|---|
| 245 |
<entry>dictionnaires de la recherche plein texte</entry> |
|---|
| 246 |
</row> |
|---|
| 247 |
|
|---|
| 248 |
<row> |
|---|
| 249 |
<entry><link linkend="catalog-pg-ts-parser"><structname>pg_ts_parser</structname></link></entry> |
|---|
| 250 |
<entry>analyseurs de la recherche plein texte</entry> |
|---|
| 251 |
</row> |
|---|
| 252 |
|
|---|
| 253 |
<row> |
|---|
| 254 |
<entry><link linkend="catalog-pg-ts-template"><structname>pg_ts_template</structname></link></entry> |
|---|
| 255 |
<entry>modèles de la recherche plein texte</entry> |
|---|
| 256 |
</row> |
|---|
| 257 |
|
|---|
| 258 |
<row> |
|---|
| 259 |
<entry><link linkend="catalog-pg-type"><structname>pg_type</structname></link></entry> |
|---|
| 260 |
<entry>types de données</entry> |
|---|
| 261 |
</row> |
|---|
| 262 |
</tbody> |
|---|
| 263 |
</tgroup> |
|---|
| 264 |
</table> |
|---|
| 265 |
</sect1> |
|---|
| 266 |
|
|---|
| 267 |
|
|---|
| 268 |
<sect1 id="catalog-pg-aggregate"> |
|---|
| 269 |
<title><structname>pg_aggregate</structname></title> |
|---|
| 270 |
|
|---|
| 271 |
<indexterm zone="catalog-pg-aggregate"> |
|---|
| 272 |
<primary>pg_aggregate</primary> |
|---|
| 273 |
</indexterm> |
|---|
| 274 |
|
|---|
| 275 |
<para> |
|---|
| 276 |
Le catalogue <structname>pg_aggregate</structname> stocke les informations |
|---|
| 277 |
concernant les fonctions d'agrégat. Une fonction d'agrégat est une fonction |
|---|
| 278 |
qui opère sur un ensemble de données (typiquement une colonne de chaque ligne |
|---|
| 279 |
qui correspond à une condition de requête) et retourne une valeur unique |
|---|
| 280 |
calculée à partir de toutes ces valeurs. |
|---|
| 281 |
Les fonctions d'agrégat classiques sont |
|---|
| 282 |
<function>sum</function> (somme), <function>count</function> (compteur) et |
|---|
| 283 |
<function>max</function> (plus grande valeur). Chaque entrée de |
|---|
| 284 |
<structname>pg_aggregate</structname> est une extension d'une entrée de |
|---|
| 285 |
<structname>pg_proc</structname>. L'entrée de <structname>pg_proc</structname> |
|---|
| 286 |
contient le nom de l'agrégat, les types de données d'entrée et de sortie, et |
|---|
| 287 |
d'autres informations similaires aux fonctions ordinaires. |
|---|
| 288 |
</para> |
|---|
| 289 |
|
|---|
| 290 |
<table> |
|---|
| 291 |
<title>Les colonnes de <structname>pg_aggregate</structname></title> |
|---|
| 292 |
|
|---|
| 293 |
<tgroup cols="4"> |
|---|
| 294 |
<colspec colnum="1" colwidth="1.0*"/> |
|---|
| 295 |
<colspec colnum="2" colwidth="0.7*"/> |
|---|
| 296 |
<colspec colnum="3" colwidth="0.7*"/> |
|---|
| 297 |
<colspec colnum="4" colwidth="1.6*"/> |
|---|
| 298 |
<thead> |
|---|
| 299 |
<row> |
|---|
| 300 |
<entry>Nom</entry> |
|---|
| 301 |
<entry>Type</entry> |
|---|
| 302 |
<entry>Références</entry> |
|---|
| 303 |
<entry>Description</entry> |
|---|
| 304 |
</row> |
|---|
| 305 |
</thead> |
|---|
| 306 |
<tbody> |
|---|
| 307 |
<row> |
|---|
| 308 |
<entry><structfield>aggfnoid</structfield></entry> |
|---|
| 309 |
<entry><type>regproc</type></entry> |
|---|
| 310 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 311 |
<entry>OID <structname>pg_proc</structname> de la fonction d'agrégat</entry> |
|---|
| 312 |
</row> |
|---|
| 313 |
<row> |
|---|
| 314 |
<entry><structfield>aggtransfn</structfield></entry> |
|---|
| 315 |
<entry><type>regproc</type></entry> |
|---|
| 316 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 317 |
<entry>Fonction de transition</entry> |
|---|
| 318 |
</row> |
|---|
| 319 |
<row> |
|---|
| 320 |
<entry><structfield>aggfinalfn</structfield></entry> |
|---|
| 321 |
<entry><type>regproc</type></entry> |
|---|
| 322 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 323 |
<entry>Fonction finale (0 s'il n'y en a pas)</entry> |
|---|
| 324 |
</row> |
|---|
| 325 |
<row> |
|---|
| 326 |
<entry><structfield>aggsortop</structfield></entry> |
|---|
| 327 |
<entry><type>oid</type></entry> |
|---|
| 328 |
<entry><literal><link linkend="catalog-pg-operator"><structname>pg_operator</structname></link>.oid</literal></entry> |
|---|
| 329 |
<entry>Opérateur de tri associé (0 s'il n'y en a pas)</entry> |
|---|
| 330 |
</row> |
|---|
| 331 |
<row> |
|---|
| 332 |
<entry><structfield>aggtranstype</structfield></entry> |
|---|
| 333 |
<entry><type>oid</type></entry> |
|---|
| 334 |
<entry><literal><link linkend="catalog-pg-type"><structname>pg_type</structname></link>.oid</literal></entry> |
|---|
| 335 |
<entry>Type de la donnée interne de transition (état) de la fonction d'agrégat</entry> |
|---|
| 336 |
</row> |
|---|
| 337 |
<row> |
|---|
| 338 |
<entry><structfield>agginitval</structfield></entry> |
|---|
| 339 |
<entry><type>text</type></entry> |
|---|
| 340 |
<entry></entry> |
|---|
| 341 |
<entry> |
|---|
| 342 |
Valeur initiale de la fonction de transition. C'est un champ texte qui |
|---|
| 343 |
contient la valeur initiale dans sa représentation externe en chaîne de |
|---|
| 344 |
caractères. Si ce champ est NULL, la valeur d'état de transition |
|---|
| 345 |
est initialement NULL. |
|---|
| 346 |
</entry> |
|---|
| 347 |
</row> |
|---|
| 348 |
</tbody> |
|---|
| 349 |
</tgroup> |
|---|
| 350 |
</table> |
|---|
| 351 |
|
|---|
| 352 |
<para> |
|---|
| 353 |
Les nouvelles fonctions d'agrégat sont enregistrées avec la commande |
|---|
| 354 |
<xref linkend="sql-createaggregate" endterm="sql-createaggregate-title"/>. |
|---|
| 355 |
La <xref linkend="xaggr"/> fournit de plus amples informations sur |
|---|
| 356 |
l'écriture des fonctions d'agrégat et sur |
|---|
| 357 |
la signification des fonctions de transition. |
|---|
| 358 |
</para> |
|---|
| 359 |
|
|---|
| 360 |
</sect1> |
|---|
| 361 |
|
|---|
| 362 |
<sect1 id="catalog-pg-am"> |
|---|
| 363 |
<title><structname>pg_am</structname></title> |
|---|
| 364 |
|
|---|
| 365 |
<indexterm zone="catalog-pg-am"> |
|---|
| 366 |
<primary>pg_am</primary> |
|---|
| 367 |
</indexterm> |
|---|
| 368 |
|
|---|
| 369 |
<para> |
|---|
| 370 |
Le catalogue <structname>pg_am</structname> stocke les informations |
|---|
| 371 |
concernant les méthodes d'accès aux index. On trouve une ligne par méthode d'accès |
|---|
| 372 |
supportée par le système. Le contenu de ce catalogue est discuté en détails |
|---|
| 373 |
dans <xref linkend="indexam"/>. |
|---|
| 374 |
</para> |
|---|
| 375 |
|
|---|
| 376 |
<table> |
|---|
| 377 |
<title>Colonnes de <structname>pg_am</structname></title> |
|---|
| 378 |
|
|---|
| 379 |
<tgroup cols="4"> |
|---|
| 380 |
<colspec colnum="1" colwidth="1.0*"/> |
|---|
| 381 |
<colspec colnum="2" colwidth="0.7*"/> |
|---|
| 382 |
<colspec colnum="3" colwidth="0.7*"/> |
|---|
| 383 |
<colspec colnum="4" colwidth="1.6*"/> |
|---|
| 384 |
<thead> |
|---|
| 385 |
<row> |
|---|
| 386 |
<entry>Nom</entry> |
|---|
| 387 |
<entry>Type</entry> |
|---|
| 388 |
<entry>Références</entry> |
|---|
| 389 |
<entry>Description</entry> |
|---|
| 390 |
</row> |
|---|
| 391 |
</thead> |
|---|
| 392 |
<tbody> |
|---|
| 393 |
|
|---|
| 394 |
<row> |
|---|
| 395 |
<entry><structfield>amname</structfield></entry> |
|---|
| 396 |
<entry><type>name</type></entry> |
|---|
| 397 |
<entry></entry> |
|---|
| 398 |
<entry>Nom de la méthode d'accès</entry> |
|---|
| 399 |
</row> |
|---|
| 400 |
|
|---|
| 401 |
<row> |
|---|
| 402 |
<entry><structfield>amstrategies</structfield></entry> |
|---|
| 403 |
<entry><type>int2</type></entry> |
|---|
| 404 |
<entry></entry> |
|---|
| 405 |
<entry>Nombre de stratégies d'opérateur pour cette méthode d'accès, |
|---|
| 406 |
ou zéro si la méthode d'accès n'a pas un ensemble fixe de stratégies |
|---|
| 407 |
opérateurs</entry> |
|---|
| 408 |
</row> |
|---|
| 409 |
|
|---|
| 410 |
<row> |
|---|
| 411 |
<entry><structfield>amsupport</structfield></entry> |
|---|
| 412 |
<entry><type>int2</type></entry> |
|---|
| 413 |
<entry></entry> |
|---|
| 414 |
<entry>Nombre de routines de support pour cette méthode d'accès</entry> |
|---|
| 415 |
</row> |
|---|
| 416 |
|
|---|
| 417 |
<row> |
|---|
| 418 |
<entry><structfield>amcanorder</structfield></entry> |
|---|
| 419 |
<entry><type>bool</type></entry> |
|---|
| 420 |
<entry></entry> |
|---|
| 421 |
<entry>La méthode d'accès supporte-t-elle les parcours |
|---|
| 422 |
ordonnés ?</entry> |
|---|
| 423 |
</row> |
|---|
| 424 |
|
|---|
| 425 |
<row> |
|---|
| 426 |
<entry><structfield>amcanunique</structfield></entry> |
|---|
| 427 |
<entry><type>bool</type></entry> |
|---|
| 428 |
<entry></entry> |
|---|
| 429 |
<entry>La méthode d'accès supporte-t-elle les index |
|---|
| 430 |
uniques ?</entry> |
|---|
| 431 |
</row> |
|---|
| 432 |
|
|---|
| 433 |
<row> |
|---|
| 434 |
<entry><structfield>amcanmulticol</structfield></entry> |
|---|
| 435 |
<entry><type>bool</type></entry> |
|---|
| 436 |
<entry></entry> |
|---|
| 437 |
<entry>La méthode d'accès supporte-t-elle les index |
|---|
| 438 |
multicolonnes ?</entry> |
|---|
| 439 |
</row> |
|---|
| 440 |
|
|---|
| 441 |
<row> |
|---|
| 442 |
<entry><structfield>amoptionalkey</structfield></entry> |
|---|
| 443 |
<entry><type>bool</type></entry> |
|---|
| 444 |
<entry></entry> |
|---|
| 445 |
<entry>La méthode d'accès supporte-t-elle un parcours sans |
|---|
| 446 |
contrainte pour la première colonne de l'index ?</entry> |
|---|
| 447 |
</row> |
|---|
| 448 |
|
|---|
| 449 |
<row> |
|---|
| 450 |
<entry><structfield>amindexnulls</structfield></entry> |
|---|
| 451 |
<entry><type>bool</type></entry> |
|---|
| 452 |
<entry></entry> |
|---|
| 453 |
<entry>La méthode d'accès supporte-t-elle les entrées d'index NULL ?</entry> |
|---|
| 454 |
</row> |
|---|
| 455 |
|
|---|
| 456 |
<row> |
|---|
| 457 |
<entry><structfield>amsearchnulls</structfield></entry> |
|---|
| 458 |
<entry><type>bool</type></entry> |
|---|
| 459 |
<entry></entry> |
|---|
| 460 |
<entry>La méthode d'accès supporte-t-elle les recherches |
|---|
| 461 |
IS NULL ?</entry> |
|---|
| 462 |
</row> |
|---|
| 463 |
|
|---|
| 464 |
<row> |
|---|
| 465 |
<entry><structfield>amstorage</structfield></entry> |
|---|
| 466 |
<entry><type>bool</type></entry> |
|---|
| 467 |
<entry></entry> |
|---|
| 468 |
<entry>Le type de données de stockage d'index peut-il différer du type de |
|---|
| 469 |
données de la colonne ?</entry> |
|---|
| 470 |
</row> |
|---|
| 471 |
|
|---|
| 472 |
<row> |
|---|
| 473 |
<entry><structfield>amclusterable</structfield></entry> |
|---|
| 474 |
<entry><type>bool</type></entry> |
|---|
| 475 |
<entry></entry> |
|---|
| 476 |
<entry>La commande CLUSTER peut-elle être utilisée avec un index de ce |
|---|
| 477 |
type ?</entry> |
|---|
| 478 |
</row> |
|---|
| 479 |
|
|---|
| 480 |
<row> |
|---|
| 481 |
<entry><structfield>aminsert</structfield></entry> |
|---|
| 482 |
<entry><type>regproc</type></entry> |
|---|
| 483 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 484 |
<entry>Fonction <quote>insérer cette ligne</quote></entry> |
|---|
| 485 |
</row> |
|---|
| 486 |
|
|---|
| 487 |
<row> |
|---|
| 488 |
<entry><structfield>ambeginscan</structfield></entry> |
|---|
| 489 |
<entry><type>regproc</type></entry> |
|---|
| 490 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 491 |
<entry>Fonction <quote>commencer un nouveau parcours</quote></entry> |
|---|
| 492 |
</row> |
|---|
| 493 |
|
|---|
| 494 |
<row> |
|---|
| 495 |
<entry><structfield>amgettuple</structfield></entry> |
|---|
| 496 |
<entry><type>regproc</type></entry> |
|---|
| 497 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 498 |
<entry>Fonction <quote>prochaine ligne valide</quote></entry> |
|---|
| 499 |
</row> |
|---|
| 500 |
|
|---|
| 501 |
<row> |
|---|
| 502 |
<entry><structfield>amgetmulti</structfield></entry> |
|---|
| 503 |
<entry><type>regproc</type></entry> |
|---|
| 504 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 505 |
<entry>Fonction <quote>récupérer plusieurs lignes</quote></entry> |
|---|
| 506 |
</row> |
|---|
| 507 |
|
|---|
| 508 |
<row> |
|---|
| 509 |
<entry><structfield>amrescan</structfield></entry> |
|---|
| 510 |
<entry><type>regproc</type></entry> |
|---|
| 511 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 512 |
<entry>Fonction <quote>redémarrer ce parcours</quote></entry> |
|---|
| 513 |
</row> |
|---|
| 514 |
|
|---|
| 515 |
<row> |
|---|
| 516 |
<entry><structfield>amendscan</structfield></entry> |
|---|
| 517 |
<entry><type>regproc</type></entry> |
|---|
| 518 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 519 |
<entry>Fonction <quote>arrêter ce parcours</quote></entry> |
|---|
| 520 |
</row> |
|---|
| 521 |
|
|---|
| 522 |
<row> |
|---|
| 523 |
<entry><structfield>ammarkpos</structfield></entry> |
|---|
| 524 |
<entry><type>regproc</type></entry> |
|---|
| 525 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 526 |
<entry>Fonction <quote>marquer la position actuelle du parcours</quote></entry> |
|---|
| 527 |
</row> |
|---|
| 528 |
|
|---|
| 529 |
<row> |
|---|
| 530 |
<entry><structfield>amrestrpos</structfield></entry> |
|---|
| 531 |
<entry><type>regproc</type></entry> |
|---|
| 532 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 533 |
<entry>Fonction <quote>restaurer une position de parcours marquée</quote></entry> |
|---|
| 534 |
</row> |
|---|
| 535 |
|
|---|
| 536 |
<row> |
|---|
| 537 |
<entry><structfield>ambuild</structfield></entry> |
|---|
| 538 |
<entry><type>regproc</type></entry> |
|---|
| 539 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 540 |
<entry>Fonction <quote>construire un nouvel index</quote></entry> |
|---|
| 541 |
</row> |
|---|
| 542 |
|
|---|
| 543 |
<row> |
|---|
| 544 |
<entry><structfield>ambulkdelete</structfield></entry> |
|---|
| 545 |
<entry><type>regproc</type></entry> |
|---|
| 546 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 547 |
<entry>Fonction de destruction en masse</entry> |
|---|
| 548 |
</row> |
|---|
| 549 |
|
|---|
| 550 |
<row> |
|---|
| 551 |
<entry><structfield>amvacuumcleanup</structfield></entry> |
|---|
| 552 |
<entry><type>regproc</type></entry> |
|---|
| 553 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 554 |
<entry>Fonction de nettoyage post-<command>VACUUM</command></entry> |
|---|
| 555 |
</row> |
|---|
| 556 |
|
|---|
| 557 |
<row> |
|---|
| 558 |
<entry><structfield>amcostestimate</structfield></entry> |
|---|
| 559 |
<entry><type>regproc</type></entry> |
|---|
| 560 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 561 |
<entry>Fonction d'estimation du coût de parcours d'un index</entry> |
|---|
| 562 |
</row> |
|---|
| 563 |
|
|---|
| 564 |
<row> |
|---|
| 565 |
<entry><structfield>amoptions</structfield></entry> |
|---|
| 566 |
<entry><type>regproc</type></entry> |
|---|
| 567 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 568 |
<entry>Fonction d'analyse et de validation du champ |
|---|
| 569 |
<structfield>reloptions</structfield> d'un index</entry> |
|---|
| 570 |
</row> |
|---|
| 571 |
|
|---|
| 572 |
</tbody> |
|---|
| 573 |
</tgroup> |
|---|
| 574 |
</table> |
|---|
| 575 |
|
|---|
| 576 |
</sect1> |
|---|
| 577 |
|
|---|
| 578 |
|
|---|
| 579 |
<sect1 id="catalog-pg-amop"> |
|---|
| 580 |
<title><structname>pg_amop</structname></title> |
|---|
| 581 |
|
|---|
| 582 |
<indexterm zone="catalog-pg-amop"> |
|---|
| 583 |
<primary>pg_amop</primary> |
|---|
| 584 |
</indexterm> |
|---|
| 585 |
|
|---|
| 586 |
<para> Le catalogue <structname>pg_amop</structname> stocke les informations |
|---|
| 587 |
concernant les opérateurs associés aux familles d'opérateurs des méthodes |
|---|
| 588 |
d'accès aux index. Il y a une ligne pour chaque opérateur membre d'une |
|---|
| 589 |
famille. Un opérateur peut apparaître dans plus d'une famille, mais ne peut |
|---|
| 590 |
pas apparaître dans plus d'une position à l'intérieur d'une famille. |
|---|
| 591 |
</para> |
|---|
| 592 |
|
|---|
| 593 |
<table> |
|---|
| 594 |
<title>Colonnes de <structname>pg_amop</structname></title> |
|---|
| 595 |
|
|---|
| 596 |
<tgroup cols="4"> |
|---|
| 597 |
<colspec colnum="1" colwidth="1.0*"/> |
|---|
| 598 |
<colspec colnum="2" colwidth="0.7*"/> |
|---|
| 599 |
<colspec colnum="3" colwidth="0.7*"/> |
|---|
| 600 |
<colspec colnum="4" colwidth="1.6*"/> |
|---|
| 601 |
<thead> |
|---|
| 602 |
<row> |
|---|
| 603 |
<entry>Nom</entry> |
|---|
| 604 |
<entry>Type</entry> |
|---|
| 605 |
<entry>Références</entry> |
|---|
| 606 |
<entry>Description</entry> |
|---|
| 607 |
</row> |
|---|
| 608 |
</thead> |
|---|
| 609 |
<tbody> |
|---|
| 610 |
|
|---|
| 611 |
<row> |
|---|
| 612 |
<entry><structfield>amopfamily</structfield></entry> |
|---|
| 613 |
<entry><type>oid</type></entry> |
|---|
| 614 |
<entry><literal><link linkend="catalog-pg-opfamily"><structname>pg_opfamily</structname></link>.oid</literal></entry> |
|---|
| 615 |
<entry>La famille d'opérateur</entry> |
|---|
| 616 |
</row> |
|---|
| 617 |
|
|---|
| 618 |
<row> |
|---|
| 619 |
<entry><structfield>amoplefttype</structfield></entry> |
|---|
| 620 |
<entry><type>oid</type></entry> |
|---|
| 621 |
<entry><literal><link linkend="catalog-pg-type"><structname>pg_type</structname></link>.oid</literal></entry> |
|---|
| 622 |
<entry>Type de données en entrée, côté gauche, de l'opérateur</entry> |
|---|
| 623 |
</row> |
|---|
| 624 |
|
|---|
| 625 |
<row> |
|---|
| 626 |
<entry><structfield>amoprighttype</structfield></entry> |
|---|
| 627 |
<entry><type>oid</type></entry> |
|---|
| 628 |
<entry><literal><link linkend="catalog-pg-type"><structname>pg_type</structname></link>.oid</literal></entry> |
|---|
| 629 |
<entry>Type de données en entrée, côté droit, de l'opérateur</entry> |
|---|
| 630 |
</row> |
|---|
| 631 |
|
|---|
| 632 |
<row> |
|---|
| 633 |
<entry><structfield>amopstrategy</structfield></entry> |
|---|
| 634 |
<entry><type>int2</type></entry> |
|---|
| 635 |
<entry></entry> |
|---|
| 636 |
<entry>Numéro de stratégie d'opérateur</entry> |
|---|
| 637 |
</row> |
|---|
| 638 |
|
|---|
| 639 |
<row> |
|---|
| 640 |
<entry><structfield>amopreqcheck</structfield></entry> |
|---|
| 641 |
<entry><type>bool</type></entry> |
|---|
| 642 |
<entry></entry> |
|---|
| 643 |
<entry>L'entrée de l'index doit être revérifiée</entry> |
|---|
| 644 |
</row> |
|---|
| 645 |
|
|---|
| 646 |
<row> |
|---|
| 647 |
<entry><structfield>amopopr</structfield></entry> |
|---|
| 648 |
<entry><type>oid</type></entry> |
|---|
| 649 |
<entry><literal><link linkend="catalog-pg-operator"><structname>pg_operator</structname></link>.oid</literal></entry> |
|---|
| 650 |
<entry>OID de l'opérateur</entry> |
|---|
| 651 |
</row> |
|---|
| 652 |
|
|---|
| 653 |
<row> |
|---|
| 654 |
<entry><structfield>amopmethod</structfield></entry> |
|---|
| 655 |
<entry><type>oid</type></entry> |
|---|
| 656 |
<entry><literal><link linkend="catalog-pg-am"><structname>pg_am</structname></link>.oid</literal></entry> |
|---|
| 657 |
<entry>Méthode d'accès à l'index pour cette famille d'opérateur</entry> |
|---|
| 658 |
</row> |
|---|
| 659 |
|
|---|
| 660 |
</tbody> |
|---|
| 661 |
</tgroup> |
|---|
| 662 |
</table> |
|---|
| 663 |
|
|---|
| 664 |
<para> |
|---|
| 665 |
Une entrée dans <structfield>amopmethod</structfield> doit correspondre |
|---|
| 666 |
au <structname>opfmethod</structname> de sa famille d'opérateur parent |
|---|
| 667 |
(l'inclusion de <structfield>amopmethod</structfield> à ce niveau est une dénormalisation |
|---|
| 668 |
intentionnelle de la structure du catalogue pour des raisons de performance). |
|---|
| 669 |
De plus, <structfield>amoplefttype</structfield> et |
|---|
| 670 |
<structfield>amoprighttype</structfield> doivent correspondre aux champs |
|---|
| 671 |
<structfield>oprleft</structfield> et <structfield>oprright</structfield> |
|---|
| 672 |
de l'entrée <structname>pg_operator</structname> référencée. |
|---|
| 673 |
</para> |
|---|
| 674 |
|
|---|
| 675 |
</sect1> |
|---|
| 676 |
|
|---|
| 677 |
|
|---|
| 678 |
<sect1 id="catalog-pg-amproc"> |
|---|
| 679 |
<title><structname>pg_amproc</structname></title> |
|---|
| 680 |
|
|---|
| 681 |
<indexterm zone="catalog-pg-amproc"> |
|---|
| 682 |
<primary>pg_amproc</primary> |
|---|
| 683 |
</indexterm> |
|---|
| 684 |
|
|---|
| 685 |
<para> |
|---|
| 686 |
Le catalogue <structname>pg_amproc</structname> stocke les informations |
|---|
| 687 |
concernant les procédures de support associées aux familles d'opérateurs |
|---|
| 688 |
de méthodes d'accès. Il y a une ligne pour chaque procédure de support |
|---|
| 689 |
appartenant à une famille. |
|---|
| 690 |
</para> |
|---|
| 691 |
|
|---|
| 692 |
<table> |
|---|
| 693 |
<title>Colonnes de <structname>pg_amproc</structname></title> |
|---|
| 694 |
|
|---|
| 695 |
<tgroup cols="4"> |
|---|
| 696 |
<colspec colnum="1" colwidth="1.0*"/> |
|---|
| 697 |
<colspec colnum="2" colwidth="0.7*"/> |
|---|
| 698 |
<colspec colnum="3" colwidth="0.7*"/> |
|---|
| 699 |
<colspec colnum="4" colwidth="1.6*"/> |
|---|
| 700 |
<thead> |
|---|
| 701 |
<row> |
|---|
| 702 |
<entry>Nom</entry> |
|---|
| 703 |
<entry>Type</entry> |
|---|
| 704 |
<entry>Références</entry> |
|---|
| 705 |
<entry>Description</entry> |
|---|
| 706 |
</row> |
|---|
| 707 |
</thead> |
|---|
| 708 |
<tbody> |
|---|
| 709 |
|
|---|
| 710 |
<row> |
|---|
| 711 |
<entry><structfield>amprocfamily</structfield></entry> |
|---|
| 712 |
<entry><type>oid</type></entry> |
|---|
| 713 |
<entry><literal><link linkend="catalog-pg-opfamily"><structname>pg_opfamily</structname></link>.oid</literal></entry> |
|---|
| 714 |
<entry>La famille d'opérateur</entry> |
|---|
| 715 |
</row> |
|---|
| 716 |
|
|---|
| 717 |
<row> |
|---|
| 718 |
<entry><structfield>amproclefttype</structfield></entry> |
|---|
| 719 |
<entry><type>oid</type></entry> |
|---|
| 720 |
<entry><literal><link linkend="catalog-pg-type"><structname>pg_type</structname></link>.oid</literal></entry> |
|---|
| 721 |
<entry>Type de données en entrée, côté gauche, de l'opérateur associé</entry> |
|---|
| 722 |
</row> |
|---|
| 723 |
|
|---|
| 724 |
<row> |
|---|
| 725 |
<entry><structfield>amprocrighttype</structfield></entry> |
|---|
| 726 |
<entry><type>oid</type></entry> |
|---|
| 727 |
<entry><literal><link linkend="catalog-pg-type"><structname>pg_type</structname></link>.oid</literal></entry> |
|---|
| 728 |
<entry>Type de données en entrée, côté droit, de l'opérateur associé</entry> |
|---|
| 729 |
</row> |
|---|
| 730 |
|
|---|
| 731 |
<row> |
|---|
| 732 |
<entry><structfield>amprocnum</structfield></entry> |
|---|
| 733 |
<entry><type>int2</type></entry> |
|---|
| 734 |
<entry></entry> |
|---|
| 735 |
<entry>Numéro de procédure de support</entry> |
|---|
| 736 |
</row> |
|---|
| 737 |
|
|---|
| 738 |
<row> |
|---|
| 739 |
<entry><structfield>amproc</structfield></entry> |
|---|
| 740 |
<entry><type>regproc</type></entry> |
|---|
| 741 |
<entry><literal><link linkend="catalog-pg-proc"><structname>pg_proc</structname></link>.oid</literal></entry> |
|---|
| 742 |
<entry>OID de la procédure</entry> |
|---|
| 743 |
</row> |
|---|
| 744 |
|
|---|
| 745 |
</tbody> |
|---|
| 746 |
</tgroup> |
|---|
| 747 |
</table> |
|---|
| 748 |
|
|---|
| 749 |
<para> |
|---|
| 750 |
On interprète habituellement les champs |
|---|
| 751 |
<structfield>amproclefttype</structfield> et |
|---|
| 752 |
<structfield>amprocrighttype</structfield> comme identifiant les types |
|---|
| 753 |
de données des côtés gauche et droit d'opérateur(s) supporté(s) par une procédure |
|---|
| 754 |
particulière. Pour certaines méthodes d'accès, ils correspondent |
|---|
| 755 |
aux types de données en entrée de la procédure elle-même. Il existe une |
|---|
| 756 |
notion de procédures de support par <quote>défaut</quote> pour un index, |
|---|
| 757 |
procédures pour lesquelles <structfield>amproclefttype</structfield> et |
|---|
| 758 |
<structfield>amprocrighttype</structfield> sont tous deux équivalents à |
|---|
| 759 |
l'<structfield>opcintype</structfield> de l'opclass de l'index. |
|---|
| 760 |
</para> |
|---|
| 761 |
|
|---|
| 762 |
</sect1> |
|---|
| 763 |
|
|---|
| 764 |
|
|---|
| 765 |
<sect1 id="catalog-pg-attrdef"> |
|---|
| 766 |
<title><structname>pg_attrdef</structname></title> |
|---|
| 767 |
|
|---|
| 768 |
<indexterm zone="catalog-pg-attrdef"> |
|---|
| 769 |
<primary>pg_attrdef</primary> |
|---|
| 770 |
</indexterm> |
|---|
| 771 |
|
|---|
| 772 |
<para> |
|---|
| 773 |
Le catalogue <structname>pg_attrdef</structname> stocke les valeurs par |
|---|
| 774 |
défaut des colonnes. Les informations principales des colonnes sont stockées |
|---|
| 775 |
dans <structname>pg_attribute</structname> (voir plus loin). Seules les |
|---|
| 776 |
colonnes pour lesquelles une valeur par défaut est explicitement indiquée |
|---|
| 777 |
(quand la table est créée ou quand une colonne est ajoutée) ont une entrée dans |
|---|
| 778 |
<structname>pg_attrdef</structname>. |
|---|
| 779 |
</para> |
|---|
| 780 |
|
|---|
| 781 |
<table> |
|---|
| 782 |
<title>Colonnes de <structname>pg_attrdef</structname></title> |
|---|
| 783 |
|
|---|
| 784 |
<tgroup cols="4"> |
|---|
| 785 |
<colspec colnum="1" colwidth="0.7*"/> |
|---|
| 786 |
<colspec colnum="2" colwidth="0.5*"/> |
|---|
| 787 |
<colspec colnum="3" colwidth="1.0*"/> |
|---|
| 788 |
<colspec colnum="4" colwidth="1.8*"/> |
|---|
| 789 |
<thead> |
|---|
| 790 |
<row> |
|---|
| 791 |
<entry>Nom</entry> |
|---|
| 792 |
<entry>Type</entry> |
|---|
| 793 |
<entry>Références</entry> |
|---|
| 794 |
<entry>Description</entry> |
|---|
| 795 |
</row> |
|---|
| 796 |
</thead> |
|---|
| 797 |
|
|---|
| 798 |
<tbody> |
|---|
| 799 |
<row> |
|---|
| 800 |
<entry><structfield>adrelid</structfield></entry> |
|---|
| 801 |
<entry><type>oid</type></entry> |
|---|
| 802 |
<entry><literal><link linkend="catalog-pg-class"><structname>pg_class</structname></link>.oid</literal></entry> |
|---|
| 803 |
<entry>La table à laquelle appartient la colonne</entry> |
|---|
| 804 |
</row> |
|---|
| 805 |
|
|---|
| 806 |
<row> |
|---|
| 807 |
<entry><structfield>adnum</structfield></entry> |
|---|
| 808 |
<entry><type>int2</type></entry> |
|---|
| 809 |
<entry><literal><link linkend="catalog-pg-attribute"><structname>pg_attribute</structname></link>.attnum</literal></entry> |
|---|
| 810 |
<entry>Numéro de la colonne</entry> |
|---|
| 811 |
</row> |
|---|
| 812 |
|
|---|
| 813 |
<row> |
|---|
| 814 |
<entry><structfield>adbin</structfield></entry> |
|---|
| 815 |
<entry><type>text</type></entry> |
|---|
| 816 |
<entry></entry> |
|---|
| 817 |
<entry>Représentation interne de la valeur par défaut de la colonne</entry> |
|---|
| 818 |
</row> |
|---|
| 819 |
|
|---|
| 820 |
<row> |
|---|
| 821 |
<entry><structfield>adsrc</structfield></entry> |
|---|
| 822 |
<entry><type>text</type></entry> |
|---|
| 823 |
<entry></entry> |
|---|
| 824 |
<entry>Représentation lisible de la valeur par défaut</entry> |
|---|
| 825 |
</row> |
|---|
| 826 |
</tbody> |
|---|
| 827 |
</tgroup> |
|---|
| 828 |
</table> |
|---|
| 829 |
|
|---|
| 830 |
<para> |
|---|
| 831 |
Le champ <structfield>adsrc</structfield> est historique. Il est |
|---|
| 832 |
préférable |
|---|
| 833 |
de ne pas l'utiliser parce qu'il ne conserve pas de trace des modifications qui |
|---|
| 834 |
peuvent affecter la représentation de la valeur par défaut. La |
|---|
| 835 |
compilation inverse du champ <structfield>adbin</structfield> (avec |
|---|
| 836 |
<function>pg_get_expr</function> par exemple) est une meilleure façon d'afficher la |
|---|
| 837 |
valeur par défaut. |
|---|
| 838 |
</para> |
|---|
| 839 |
|
|---|
| 840 |
</sect1> |
|---|
| 841 |
|
|---|
| 842 |
|
|---|
| 843 |
<sect1 id="catalog-pg-attribute"> |
|---|
| 844 |
<title><structname>pg_attribute</structname></title> |
|---|
| 845 |
|
|---|
| 846 |
<indexterm zone="catalog-pg-attribute"> |
|---|
| 847 |
<primary>pg_attribute</primary> |
|---|
| 848 |
</indexterm> |
|---|
| 849 |
|
|---|
| 850 |
<para> |
|---|
| 851 |
Le catalogue <structname>pg_attribute</structname> stocke les informations |
|---|
| 852 |
concernant les colonnes des tables. Il y a exactement une ligne de |
|---|
| 853 |
<structname>pg_attribute</structname> par colonne de table de |
|---|
| 854 |
la base de données. (Il y a aussi des attributs pour les index et, en fait, |
|---|
| 855 |
tous les objets qui possèdent des entrées dans <structname>pg_class</structname>.) |
|---|
| 856 |
</para> |
|---|
| 857 |
|
|---|
| 858 |
<para> |
|---|
| 859 |
Le terme attribut, équivalent à colonne, est utilisé pour des raisons |
|---|
| 860 |
historiques. |
|---|
| 861 |
</para> |
|---|
| 862 |
|
|---|
| 863 |
<table> |
|---|
| 864 |
<title>Colonnes de <structname>pg_attribute</structname></title> |
|---|
| 865 |
|
|---|
| 866 |
<tgroup cols="4"> |
|---|
| 867 |
<colspec colnum="1" colwidth="1.0*"/> |
|---|
| 868 |
<colspec colnum="2" colwidth="0.7*"/> |
|---|
| 869 |
<colspec colnum="3" colwidth="0.7*"/> |
|---|
| 870 |
<colspec colnum="4" colwidth="1.6*"/> |
|---|
| 871 |
<thead> |
|---|
| 872 |
<row> |
|---|
| 873 |
<entry>Nom</entry> |
|---|
| 874 |
<entry>Type</entry> |
|---|
| 875 |
<entry>Références</entry> |
|---|
| 876 |
<entry>Description</entry> |
|---|
| 877 |
</row> |
|---|
| 878 |
</thead> |
|---|
| 879 |
|
|---|
| 880 |
<tbody> |
|---|
| 881 |
<row> |
|---|
| 882 |
<entry><structfield>attrelid</structfield></entry> |
|---|
| 883 |
<entry><type>oid</type></entry> |
|---|
| 884 |
<entry><literal><link linkend="catalog-pg-class"><structname>pg_class</structname></link>.oid</literal></entry> |
|---|
| 885 |
<entry>La table à laquelle appartient la colonne</entry> |
|---|
| 886 |
</row> |
|---|
| 887 |
|
|---|
| 888 |
<row> |
|---|
| 889 |
<entry><structfield>attname</structfield></entry> |
|---|
| 890 |
<entry><type>name</type></entry> |
|---|
| 891 |
<entry></entry> |
|---|
| 892 |
<entry>Le nom de la colonne</entry> |
|---|
| 893 |
</row> |
|---|
| 894 |
|
|---|
| 895 |
<row> |
|---|
| 896 |
<entry><structfield>atttypid</structfield></entry> |
|---|
| 897 |
<entry><type>oid</type></entry> |
|---|
| 898 |
<entry><literal><link linkend="catalog-pg-type"><structname>pg_type</structname></link>.oid</literal></entry> |
|---|
| 899 |
<entry>Le type de données de la colonne</entry> |
|---|
| 900 |
</row> |
|---|
| 901 |
|
|---|
| 902 |
<row> |
|---|
| 903 |
<entry><structfield>attstattarget</structfield></entry> |
|---|
| 904 |
<entry><type>int4</type></entry> |
|---|
| 905 |
<entry></entry> |
|---|
| 906 |
<entry> |
|---|
| 907 |
Contrôle le niveau de détail des |
|---|
| 908 |
statistiques accumulées pour la colonne par |
|---|
| 909 |
<xref linkend="sql-analyze" endterm="sql-analyze-title"/>. |
|---|
| 910 |
Une valeur 0 indique qu'aucune statistique ne doit être collectée. |
|---|
| 911 |
Une valeur négative indique d'utiliser l'objectif de statistiques |
|---|
| 912 |
par défaut. |
|---|
| 913 |
Le sens exact d'une valeur positive dépend du type de données. |
|---|
| 914 |
Pour les données scalaires, <structfield>attstattarget</structfield> |
|---|
| 915 |
est à la fois le nombre de <quote>valeurs les plus courantes</quote> |
|---|
| 916 |
à collecter et le nombre d'histogrammes à créer. |
|---|
| 917 |
</entry> |
|---|
| 918 |
</row> |
|---|
| 919 |
|
|---|
| 920 |
<row> |
|---|
| 921 |
<entry><structfield>attlen</structfield></entry> |
|---|
| 922 |
<entry><type>int2</type></entry> |
|---|
| 923 |
<entry></entry> |
|---|
| 924 |
<entry> |
|---|
| 925 |
Une copie de <literal>pg_type.typlen</literal> pour le type de la |
|---|
| 926 |
colonne. |
|---|
| 927 |
</entry> |
|---|
| 928 |
</row> |
|---|
| 929 |
|
|---|
| 930 |
<row> |
|---|
| 931 |
<entry><structfield>attnum</structfield></entry> |
|---|
| 932 |
<entry><type>int2</type></entry> |
|---|
| 933 |
<entry></entry> |
|---|
| 934 |
<entry> |
|---|
| 935 |
Le numéro de la colonne. La numérotation des colonnes ordinaires |
|---|
| 936 |
démarre à 1. Les colonnes système, comme les |
|---|
| 937 |
<structfield>oid</structfield>, ont des numéros négatifs arbitraires. |
|---|
| 938 |
</entry> |
|---|
| 939 |
</row> |
|---|
| 940 |
|
|---|
| 941 |
<row> |
|---|
| 942 |
<entry><structfield>attndims</structfield></entry> |
|---|
| 943 |
<entry><type>int4</type></entry> |
|---|
| 944 |
<entry></entry> |
|---|
| 945 |
<entry> |
|---|
| 946 |
Nombre de dimensions, si la colonne est de type tableau, sinon 0. |
|---|
| 947 |
(Pour l'instant, le nombre de dimensions des tableaux n'est pas contrôlé, |
|---|
| 948 |
donc une valeur autre que 0 indique que <quote>c'est un tableau</quote>.) |
|---|
| 949 |
</entry> |
|---|
| 950 |
</row> |
|---|
| 951 |
|
|---|
| 952 |
<row> |
|---|
| 953 |
<entry><structfield>attcacheoff</structfield></entry> |
|---|
| 954 |
<entry><type>int4</type></entry> |
|---|
| 955 |
<entry></entry> |
|---|
| 956 |
<entry> |
|---|
| 957 |
Toujours -1 sur disque, mais peut être mis à jour lorsque la ligne |
|---|
| 958 |
est chargée en mémoire, pour |
|---|
| 959 |
mettre en cache l'emplacement de l'attribut dans la ligne. |
|---|
| 960 |
</entry> |
|---|
| 961 |
</row> |
|---|
| 962 |
|
|---|
| 963 |
<row> |
|---|
| 964 |
<entry><structfield>atttypmod</structfield></entry> |
|---|
| 965 |
<entry><type>int4</type></entry> |
|---|
| 966 |
<entry></entry> |
|---|
| 967 |
<entry> |
|---|
| 968 |
Stocke des données spécifiques au type |
|---|
| 969 |
de données précisé lors de la création de la table (par exemple, la |
|---|
| 970 |
taille maximale d'une colonne de type <type>varchar</type>). Il est |
|---|
| 971 |
transmis aux fonctions spécifiques au type d'entrée de données et de |
|---|
| 972 |
vérification de taille. La valeur est généralement -1 pour les types |
|---|
| 973 |
de données qui n'ont pas besoin de <structfield>atttypmod</structfield>. |
|---|
| 974 |
</entry> |
|---|
| 975 |
</row> |
|---|
| 976 |
|
|---|
| 977 |
<row> |
|---|
| 978 |
<entry><structfield>attbyval</structfield></entry> |
|---|
| 979 |
<entry><type>bool</type></entry> |
|---|
| 980 |
<entry></entry> |
|---|
| 981 |
<entry> |
|---|
| 982 |
Une copie de <literal>pg_type.typbyval</literal> du type de la |
|---|
| 983 |
colonne. |
|---|
| 984 |
</entry> |
|---|
| 985 |
</row> |
|---|
| 986 |
|
|---|
| 987 |
<row> |
|---|
| 988 |
<entry><structfield>attstorage</structfield></entry> |
|---|
| 989 |
<entry><type>char</type></entry> |
|---|
| 990 |
<entry></entry> |
|---|
| 991 |
<entry> |
|---|
| 992 |
Contient normalement une copie de |
|---|
| 993 |
<literal>pg_type.typstorage</literal> du type de la colonne. |
|---|
| 994 |
Pour les types de données TOASTables, cette valeur |
|---|
| 995 |
peut être modifiée après la création de la colonne pour en contrôler |
|---|
| 996 |
les règles de stockage. |
|---|
| 997 |
</entry> |
|---|
| 998 |
</row> |
|---|
| 999 |
|
|---|
| 1000 |
<row> |
|---|
| 1001 |
<entry><structfield>attalign</structfield></entry> |
|---|
| 1002 |
<entry><type>char</type></entry> |
|---|
| 1003 |
<entry></entry> |
|---|
| 1004 |
<entry> |
|---|
| 1005 |
Une copie de <literal>pg_type.typalign</literal> du type de |
|---|
| 1006 |
la colonne. |
|---|
| 1007 |
</entry> |
|---|
| 1008 |
</row> |
|---|
| 1009 |
|
|---|
| 1010 |
<row> |
|---|
| 1011 |
<entry><structfield>attnotnull</structfield></entry> |
|---|
| 1012 |
<entry><type>bool</type></entry> |
|---|
| 1013 |
<entry></entry> |
|---|
| 1014 |
<entry> |
|---|
| 1015 |
Indique une contrainte de non-nullité de colonne. Il est possible de changer |
|---|
| 1016 |
cette colonne pour activer ou désactiver cette contrainte. |
|---|
| 1017 |
</entry> |
|---|
| 1018 |
</row> |
|---|
| 1019 |
|
|---|
| 1020 |
<row> |
|---|
| 1021 |
<entry><structfield>atthasdef</structfield></entry> |
|---|
| 1022 |
<entry><type>bool</type></entry> |
|---|
| 1023 |
<entry></entry> |
|---|
| 1024 |
<entry> |
|---|
| 1025 |
Indique que la colonne a une valeur par défaut. Dans ce cas, il y |
|---|
| 1026 |
a une entrée correspondante dans le catalogue |
|---|
| 1027 |
<structname>pg_attrdef</structname> pour définir cette valeur. |
|---|
| 1028 |
</entry> |
|---|
| 1029 |
</row> |
|---|
| 1030 |
|
|---|
| 1031 |
<row> |
|---|
| 1032 |
<entry><structfield>attisdropped</structfield></entry> |
|---|
| 1033 |
<entry><type>bool</type></entry> |
|---|
| 1034 |
<entry></entry> |
|---|
| 1035 |
<entry> |
|---|
| 1036 |
Indique que la colonne a été supprimée et n'est plus valide. Une |
|---|
| 1037 |
colonne supprimée est toujours présente physiquement dans la table, |
|---|
| 1038 |
mais elle est ignorée par l'analyseur de |
|---|