<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>pg_namespace &#8211; Database Research &amp; Development</title>
	<atom:link href="https://www.dbrnd.com/tag/pg_namespace/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.dbrnd.com</link>
	<description>BIGData &#124; NoSQL &#124; MSSQL &#124; MySQL &#124; PostgreSQL</description>
	<lastBuildDate>Thu, 29 Jun 2017 18:37:05 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.6</generator>
	<item>
		<title>Greenplum: How to check the Database Schema Size?</title>
		<link>https://www.dbrnd.com/2017/06/greenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk/</link>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Thu, 29 Jun 2017 16:16:21 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Anvesh Patel]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[database research and development]]></category>
		<category><![CDATA[dbrnd]]></category>
		<category><![CDATA[gp_size_of_schema_disk]]></category>
		<category><![CDATA[gp_toolkit]]></category>
		<category><![CDATA[Greenplum]]></category>
		<category><![CDATA[Greenplum Administrator]]></category>
		<category><![CDATA[Greenplum Error]]></category>
		<category><![CDATA[Greenplum Monitoring]]></category>
		<category><![CDATA[Greenplum Performance Tuning]]></category>
		<category><![CDATA[Greenplum Programming]]></category>
		<category><![CDATA[Greenplum Query]]></category>
		<category><![CDATA[Greenplum Tips and Tricks]]></category>
		<category><![CDATA[pg_namespace]]></category>
		<category><![CDATA[PostgreSQL 8.2]]></category>
		<category><![CDATA[schema]]></category>
		<category><![CDATA[size]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=5441</guid>

					<description><![CDATA[Greenplum is a based on MVCC architecture that means user&#8217;s action like UPDATE will insert a new record in a database. Greenplum Data warehouse can manage billions of data, but it doesn&#8217;t mean that user can generate or UPDATE random data set. Periodically, The Greenplum DBA should check the size of database schemas and their [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a class="a2a_button_facebook" href="https://www.addtoany.com/add_to/facebook?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&amp;linkname=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" title="Facebook" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_twitter" href="https://www.addtoany.com/add_to/twitter?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&amp;linkname=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" title="Twitter" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_linkedin" href="https://www.addtoany.com/add_to/linkedin?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&amp;linkname=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" title="LinkedIn" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&amp;linkname=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_reddit" href="https://www.addtoany.com/add_to/reddit?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&amp;linkname=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" title="Reddit" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&amp;linkname=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" title="Pocket" rel="nofollow noopener" target="_blank"></a><a class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fwww.dbrnd.com%2F2017%2F06%2Fgreenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk%2F&#038;title=Greenplum%3A%20How%20to%20check%20the%20Database%20Schema%20Size%3F" data-a2a-url="https://www.dbrnd.com/2017/06/greenplum-how-to-check-the-database-schema-size-gp_toolkit-gp_size_of_schema_disk/" data-a2a-title="Greenplum: How to check the Database Schema Size?"></a></p><p>Greenplum is a based on MVCC architecture that means user&#8217;s action like UPDATE will insert a new record in a database.<br />
Greenplum Data warehouse can manage billions of data, but it doesn&#8217;t mean that user can generate or UPDATE random data set.<br />
Periodically, The Greenplum DBA should check the size of database schemas and their appropriate usage.</p>
<p>In this post, I shared different scripts to check the size of Greenplum Database Schemas.</p>
<p><strong>Option 1:</strong></p>
<pre class="crayon-plain-tag">select *
from gp_toolkit.gp_size_of_schema_disk;</pre> </p>
<p><strong>Option 2:</strong></p>
<pre class="crayon-plain-tag">select
	schemaname
	,round(sum(pg_total_relation_size(schemaname||'.'||tablename))) SchemaSize
from pg_tables group by 1;</pre> </p>
<p><strong>Option 3:</strong></p>
<pre class="crayon-plain-tag">SELECT
	schema_name
	,pg_size_pretty(sum(table_size)::bigint)
FROM
(
	SELECT pg_catalog.pg_namespace.nspname as schema_name,
	pg_relation_size(pg_catalog.pg_class.oid) as table_size
	FROM pg_catalog.pg_class
	JOIN pg_catalog.pg_namespace ON relnamespace = pg_catalog.pg_namespace.oid
) t
GROUP BY schema_name
ORDER BY schema_name;</pre> </p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
