forked from docs/doc-exports
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com> Co-authored-by: Lu, Huayi <luhuayi@huawei.com> Co-committed-by: Lu, Huayi <luhuayi@huawei.com>
16 lines
1.1 KiB
HTML
16 lines
1.1 KiB
HTML
<a name="EN-US_TOPIC_0000001192706419"></a><a name="EN-US_TOPIC_0000001192706419"></a>
|
|
|
|
<h1 class="topictitle1">How Can I Export All Tables and Views from a Database?</h1>
|
|
<div id="body8662426"><p id="EN-US_TOPIC_0000001192706419__en-us_topic_0000001098656874_p8060118">You can use <strong id="EN-US_TOPIC_0000001192706419__b135103233317">pg_tables</strong> and <strong id="EN-US_TOPIC_0000001192706419__b161284264316">pg_views</strong> to query all table information and views in a database. Example:</p>
|
|
<pre class="screen" id="EN-US_TOPIC_0000001192706419__en-us_topic_0000001098656874_screen4825135312119">SELECT * FROM pg_tables;
|
|
SELECT * FROM pg_views;</pre>
|
|
<p id="EN-US_TOPIC_0000001192706419__en-us_topic_0000001098656874_p68901411856"></p>
|
|
<p id="EN-US_TOPIC_0000001192706419__en-us_topic_0000001098656874_p15729228101210">For details about the returned columns, see "PG_TABLES" and "PG_VIEWS" in the <em id="EN-US_TOPIC_0000001192706419__i10733655101511">Developer Guide</em>.</p>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="dws_03_0065.html">Database Usage</a></div>
|
|
</div>
|
|
</div>
|
|
|