|
1 |
| -<!-- $PostgreSQL: pgsql/doc/src/sgml/catalogs.sgml,v 2.184 2008/12/18 18:20:33 tgl Exp $ --> |
| 1 | +<!-- $PostgreSQL: pgsql/doc/src/sgml/catalogs.sgml,v 2.185 2008/12/19 16:25:16 petere Exp $ --> |
2 | 2 | <!--
|
3 | 3 | Documentation of the system catalogs, directed toward PostgreSQL developers
|
4 | 4 | -->
|
|
133 | 133 | <entry>enum label and value definitions</entry>
|
134 | 134 | </row>
|
135 | 135 |
|
| 136 | + <row> |
| 137 | + <entry><link linkend="catalog-pg-foreign-data-wrapper"><structname>pg_foreign_data_wrapper</structname></link></entry> |
| 138 | + <entry>foreign-data wrapper definitions</entry> |
| 139 | + </row> |
| 140 | + |
| 141 | + <row> |
| 142 | + <entry><link linkend="catalog-pg-foreign-server"><structname>pg_foreign_server</structname></link></entry> |
| 143 | + <entry>foreign server definitions</entry> |
| 144 | + </row> |
| 145 | + |
136 | 146 | <row>
|
137 | 147 | <entry><link linkend="catalog-pg-index"><structname>pg_index</structname></link></entry>
|
138 | 148 | <entry>additional index information</entry>
|
|
247 | 257 | <entry><link linkend="catalog-pg-type"><structname>pg_type</structname></link></entry>
|
248 | 258 | <entry>data types</entry>
|
249 | 259 | </row>
|
| 260 | + |
| 261 | + <row> |
| 262 | + <entry><link linkend="catalog-pg-user-mapping"><structname>pg_user_mapping</structname></link></entry> |
| 263 | + <entry>mappings of users to foreign servers</entry> |
| 264 | + </row> |
250 | 265 | </tbody>
|
251 | 266 | </tgroup>
|
252 | 267 | </table>
|
|
2552 | 2567 | </sect1>
|
2553 | 2568 |
|
2554 | 2569 |
|
| 2570 | + <sect1 id="catalog-pg-foreign-data-wrapper"> |
| 2571 | + <title><structname>pg_foreign_data_wrapper</structname></title> |
| 2572 | + |
| 2573 | + <indexterm zone="catalog-pg-foreign-data-wrapper"> |
| 2574 | + <primary>pg_foreign_data_wrapper</primary> |
| 2575 | + </indexterm> |
| 2576 | + |
| 2577 | + <para> |
| 2578 | + The catalog <structname>pg_foreign_data_wrapper</structname> stores |
| 2579 | + foreign-data wrapper definitions. A foreign-data wrapper is the |
| 2580 | + mechanism by which external data, residing on foreign servers, is |
| 2581 | + accessed. |
| 2582 | + </para> |
| 2583 | + |
| 2584 | + <table> |
| 2585 | + <title><structname>pg_foreign_data_wrapper</> Columns</title> |
| 2586 | + |
| 2587 | + <tgroup cols=4> |
| 2588 | + <thead> |
| 2589 | + <row> |
| 2590 | + <entry>Name</entry> |
| 2591 | + <entry>Type</entry> |
| 2592 | + <entry>References</entry> |
| 2593 | + <entry>Description</entry> |
| 2594 | + </row> |
| 2595 | + </thead> |
| 2596 | + |
| 2597 | + <tbody> |
| 2598 | + <row> |
| 2599 | + <entry><structfield>fdwname</structfield></entry> |
| 2600 | + <entry><type>name</type></entry> |
| 2601 | + <entry></entry> |
| 2602 | + <entry>Name of the foreign-data wrapper</entry> |
| 2603 | + </row> |
| 2604 | + |
| 2605 | + <row> |
| 2606 | + <entry><structfield>fdwowner</structfield></entry> |
| 2607 | + <entry><type>oid</type></entry> |
| 2608 | + <entry><literal><link linkend="catalog-pg-authid"><structname>pg_authid</structname></link>.oid</literal></entry> |
| 2609 | + <entry>Owner of the foreign-data wrapper</entry> |
| 2610 | + </row> |
| 2611 | + |
| 2612 | + <row> |
| 2613 | + <entry><structfield>fdwlibrary</structfield></entry> |
| 2614 | + <entry><type>text</type></entry> |
| 2615 | + <entry></entry> |
| 2616 | + <entry>File name of the library implementing this foreign-data wrapper</entry> |
| 2617 | + </row> |
| 2618 | + |
| 2619 | + <row> |
| 2620 | + <entry><structfield>fdwacl</structfield></entry> |
| 2621 | + <entry><type>aclitem[]</type></entry> |
| 2622 | + <entry></entry> |
| 2623 | + <entry> |
| 2624 | + Access privileges; see |
| 2625 | + <xref linkend="sql-grant" endterm="sql-grant-title"> and |
| 2626 | + <xref linkend="sql-revoke" endterm="sql-revoke-title"> |
| 2627 | + for details |
| 2628 | + </entry> |
| 2629 | + </row> |
| 2630 | + |
| 2631 | + <row> |
| 2632 | + <entry><structfield>fdwoptions</structfield></entry> |
| 2633 | + <entry><type>text[]</type></entry> |
| 2634 | + <entry></entry> |
| 2635 | + <entry> |
| 2636 | + Foreign-data wrapper specific options, as <quote>keyword=value</> strings |
| 2637 | + </entry> |
| 2638 | + </row> |
| 2639 | + </tbody> |
| 2640 | + </tgroup> |
| 2641 | + </table> |
| 2642 | + </sect1> |
| 2643 | + |
| 2644 | + |
| 2645 | + <sect1 id="catalog-pg-foreign-server"> |
| 2646 | + <title><structname>pg_foreign_server</structname></title> |
| 2647 | + |
| 2648 | + <indexterm zone="catalog-pg-foreign-server"> |
| 2649 | + <primary>pg_foreign_server</primary> |
| 2650 | + </indexterm> |
| 2651 | + |
| 2652 | + <para> |
| 2653 | + The catalog <structname>pg_foreign_server</structname> stores |
| 2654 | + foreign server definitions. A foreign server describes the |
| 2655 | + connection to a remote server, managing external data. Foreign |
| 2656 | + servers are accessed via foreign-data wrappers. |
| 2657 | + </para> |
| 2658 | + |
| 2659 | + <table> |
| 2660 | + <title><structname>pg_foreign_server</> Columns</title> |
| 2661 | + |
| 2662 | + <tgroup cols=4> |
| 2663 | + <thead> |
| 2664 | + <row> |
| 2665 | + <entry>Name</entry> |
| 2666 | + <entry>Type</entry> |
| 2667 | + <entry>References</entry> |
| 2668 | + <entry>Description</entry> |
| 2669 | + </row> |
| 2670 | + </thead> |
| 2671 | + |
| 2672 | + <tbody> |
| 2673 | + <row> |
| 2674 | + <entry><structfield>srvname</structfield></entry> |
| 2675 | + <entry><type>name</type></entry> |
| 2676 | + <entry></entry> |
| 2677 | + <entry>Name of the foreign server</entry> |
| 2678 | + </row> |
| 2679 | + |
| 2680 | + <row> |
| 2681 | + <entry><structfield>srvowner</structfield></entry> |
| 2682 | + <entry><type>oid</type></entry> |
| 2683 | + <entry><literal><link linkend="catalog-pg-authid"><structname>pg_authid</structname></link>.oid</literal></entry> |
| 2684 | + <entry>Owner of the foreign server</entry> |
| 2685 | + </row> |
| 2686 | + |
| 2687 | + <row> |
| 2688 | + <entry><structfield>srvfdw</structfield></entry> |
| 2689 | + <entry><type>oid</type></entry> |
| 2690 | + <entry><literal><link linkend="catalog-pg-foreign-data-wrapper"><structname>pg_foreign_data_wrapper</structname></link>.oid</literal></entry> |
| 2691 | + <entry>The OID of the foreign-data wrapper of this foreign server</entry> |
| 2692 | + </row> |
| 2693 | + |
| 2694 | + <row> |
| 2695 | + <entry><structfield>srvtype</structfield></entry> |
| 2696 | + <entry><type>text</type></entry> |
| 2697 | + <entry></entry> |
| 2698 | + <entry>Type of the server (optional)</entry> |
| 2699 | + </row> |
| 2700 | + |
| 2701 | + <row> |
| 2702 | + <entry><structfield>srvversion</structfield></entry> |
| 2703 | + <entry><type>text</type></entry> |
| 2704 | + <entry></entry> |
| 2705 | + <entry>Version of the server (optional)</entry> |
| 2706 | + </row> |
| 2707 | + |
| 2708 | + <row> |
| 2709 | + <entry><structfield>srvacl</structfield></entry> |
| 2710 | + <entry><type>aclitem[]</type></entry> |
| 2711 | + <entry></entry> |
| 2712 | + <entry> |
| 2713 | + Access privileges; see |
| 2714 | + <xref linkend="sql-grant" endterm="sql-grant-title"> and |
| 2715 | + <xref linkend="sql-revoke" endterm="sql-revoke-title"> |
| 2716 | + for details |
| 2717 | + </entry> |
| 2718 | + </row> |
| 2719 | + |
| 2720 | + <row> |
| 2721 | + <entry><structfield>srvoptions</structfield></entry> |
| 2722 | + <entry><type>text[]</type></entry> |
| 2723 | + <entry></entry> |
| 2724 | + <entry> |
| 2725 | + Foreign server specific options, as <quote>keyword=value</> strings. |
| 2726 | + </entry> |
| 2727 | + </row> |
| 2728 | + </tbody> |
| 2729 | + </tgroup> |
| 2730 | + </table> |
| 2731 | + </sect1> |
| 2732 | + |
| 2733 | + |
| 2734 | + <sect1 id="catalog-pg-user-mapping"> |
| 2735 | + <title><structname>pg_user_mapping</structname></title> |
| 2736 | + |
| 2737 | + <indexterm zone="catalog-pg-user-mapping"> |
| 2738 | + <primary>pg_user_mapping</primary> |
| 2739 | + </indexterm> |
| 2740 | + |
| 2741 | + <para> |
| 2742 | + The catalog <structname>pg_user_mapping</structname> stores |
| 2743 | + the mappings from local user to remote. Access to this catalog is |
| 2744 | + restricted from normal users, use the view |
| 2745 | + <link linkend="view-pg-user-mappings"><structname>pg_user_mappings</structname></link> |
| 2746 | + instead. |
| 2747 | + </para> |
| 2748 | + |
| 2749 | + <table> |
| 2750 | + <title><structname>pg_user_mapping</> Columns</title> |
| 2751 | + |
| 2752 | + <tgroup cols=4> |
| 2753 | + <thead> |
| 2754 | + <row> |
| 2755 | + <entry>Name</entry> |
| 2756 | + <entry>Type</entry> |
| 2757 | + <entry>References</entry> |
| 2758 | + <entry>Description</entry> |
| 2759 | + </row> |
| 2760 | + </thead> |
| 2761 | + |
| 2762 | + <tbody> |
| 2763 | + <row> |
| 2764 | + <entry><structfield>umuser</structfield></entry> |
| 2765 | + <entry><type>oid</type></entry> |
| 2766 | + <entry><literal><link linkend="catalog-pg-authid"><structname>pg_authid</structname></link>.oid</literal></entry> |
| 2767 | + <entry>OID of the local role being mapped, 0 if the user mapping is public</entry> |
| 2768 | + </row> |
| 2769 | + |
| 2770 | + <row> |
| 2771 | + <entry><structfield>umserver</structfield></entry> |
| 2772 | + <entry><type>oid</type></entry> |
| 2773 | + <entry><literal><link linkend="catalog-pg-foreign-server"><structname>pg_foreign_server</structname></link>.oid</literal></entry> |
| 2774 | + <entry> |
| 2775 | + The OID of the foreign server that contains this mapping |
| 2776 | + </entry> |
| 2777 | + </row> |
| 2778 | + |
| 2779 | + <row> |
| 2780 | + <entry><structfield>umoptions</structfield></entry> |
| 2781 | + <entry><type>text[]</type></entry> |
| 2782 | + <entry></entry> |
| 2783 | + <entry> |
| 2784 | + User mapping specific options, as <quote>keyword=value</> strings. |
| 2785 | + </entry> |
| 2786 | + </row> |
| 2787 | + </tbody> |
| 2788 | + </tgroup> |
| 2789 | + </table> |
| 2790 | + </sect1> |
| 2791 | + |
| 2792 | + |
2555 | 2793 | <sect1 id="catalog-pg-index">
|
2556 | 2794 | <title><structname>pg_index</structname></title>
|
2557 | 2795 |
|
|
7019 | 7257 |
|
7020 | 7258 | </sect1>
|
7021 | 7259 |
|
| 7260 | + <sect1 id="view-pg-user-mappings"> |
| 7261 | + <title><structname>pg_user_mappings</structname></title> |
| 7262 | + |
| 7263 | + <indexterm zone="view-pg-user-mappings"> |
| 7264 | + <primary>pg_user_mappings</primary> |
| 7265 | + </indexterm> |
| 7266 | + |
| 7267 | + <para> |
| 7268 | + The view <structname>pg_user_mappings</structname> provides access |
| 7269 | + to information about user mappings. This is essentially a publicly |
| 7270 | + readable view of |
| 7271 | + <link linkend="catalog-pg-user-mapping"><structname>pg_user_mapping</structname></link> |
| 7272 | + that leaves out the options field if the user has no rights to use |
| 7273 | + it. |
| 7274 | + </para> |
| 7275 | + |
| 7276 | + <table> |
| 7277 | + <title><structname>pg_user_mappings</> Columns</title> |
| 7278 | + |
| 7279 | + <tgroup cols=3> |
| 7280 | + <thead> |
| 7281 | + <row> |
| 7282 | + <entry>Name</entry> |
| 7283 | + <entry>Type</entry> |
| 7284 | + <entry>References</entry> |
| 7285 | + <entry>Description</entry> |
| 7286 | + </row> |
| 7287 | + </thead> |
| 7288 | + |
| 7289 | + <tbody> |
| 7290 | + <row> |
| 7291 | + <entry><structfield>umid</structfield></entry> |
| 7292 | + <entry><type>oid</type></entry> |
| 7293 | + <entry><literal><link linkend="catalog-pg-user-mapping"><structname>pg_user_mapping</structname></link>.oid</literal></entry> |
| 7294 | + <entry>OID of the user mapping</entry> |
| 7295 | + </row> |
| 7296 | + |
| 7297 | + <row> |
| 7298 | + <entry><structfield>srvid</structfield></entry> |
| 7299 | + <entry><type>oid</type></entry> |
| 7300 | + <entry><literal><link linkend="catalog-pg-foreign-server"><structname>pg_foreign_server</structname></link>.oid</literal></entry> |
| 7301 | + <entry> |
| 7302 | + The OID of the foreign server that contains this mapping |
| 7303 | + </entry> |
| 7304 | + </row> |
| 7305 | + |
| 7306 | + <row> |
| 7307 | + <entry><structfield>srvname</structfield></entry> |
| 7308 | + <entry><type>text</type></entry> |
| 7309 | + <entry></entry> |
| 7310 | + <entry> |
| 7311 | + Name of the foreign server |
| 7312 | + </entry> |
| 7313 | + </row> |
| 7314 | + |
| 7315 | + <row> |
| 7316 | + <entry><structfield>umuser</structfield></entry> |
| 7317 | + <entry><type>oid</type></entry> |
| 7318 | + <entry><literal><link linkend="catalog-pg-authid"><structname>pg_authid</structname></link>.oid</literal></entry> |
| 7319 | + <entry>OID of the local role being mapped, 0 if the user mapping is public</entry> |
| 7320 | + </row> |
| 7321 | + |
| 7322 | + <row> |
| 7323 | + <entry><structfield>usename</structfield></entry> |
| 7324 | + <entry><type>name</type></entry> |
| 7325 | + <entry></entry> |
| 7326 | + <entry>Name of the local user to be mapped</entry> |
| 7327 | + </row> |
| 7328 | + |
| 7329 | + <row> |
| 7330 | + <entry><structfield>umoptions</structfield></entry> |
| 7331 | + <entry><type>text[]</type></entry> |
| 7332 | + <entry></entry> |
| 7333 | + <entry> |
| 7334 | + User mapping specific options, as <quote>keyword=value</> |
| 7335 | + strings, if the current user is the owner of the foreign |
| 7336 | + server, else null. |
| 7337 | + </entry> |
| 7338 | + </row> |
| 7339 | + </tbody> |
| 7340 | + </tgroup> |
| 7341 | + </table> |
| 7342 | + </sect1> |
| 7343 | + |
| 7344 | + |
7022 | 7345 | <sect1 id="view-pg-views">
|
7023 | 7346 | <title><structname>pg_views</structname></title>
|
7024 | 7347 |
|
|
0 commit comments