<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://ebasso.net/wiki/index.php?action=history&amp;feed=atom&amp;title=Oracle%3A_SQL_Queries_-_GERAL</id>
	<title>Oracle: SQL Queries - GERAL - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://ebasso.net/wiki/index.php?action=history&amp;feed=atom&amp;title=Oracle%3A_SQL_Queries_-_GERAL"/>
	<link rel="alternate" type="text/html" href="https://ebasso.net/wiki/index.php?title=Oracle:_SQL_Queries_-_GERAL&amp;action=history"/>
	<updated>2026-06-02T11:37:55Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.40.0</generator>
	<entry>
		<id>https://ebasso.net/wiki/index.php?title=Oracle:_SQL_Queries_-_GERAL&amp;diff=7497&amp;oldid=prev</id>
		<title>Ebasso: Criou a página com &quot; == Versão do Oracle ==  Verificando as maiores tabelas e a atualização de estatísticas das tabelas.   select banner from v$version where rownum &lt; 2; resultado:  Oracle...&quot;</title>
		<link rel="alternate" type="text/html" href="https://ebasso.net/wiki/index.php?title=Oracle:_SQL_Queries_-_GERAL&amp;diff=7497&amp;oldid=prev"/>
		<updated>2022-02-12T14:26:39Z</updated>

		<summary type="html">&lt;p&gt;Criou a página com &amp;quot; == Versão do Oracle ==  Verificando as maiores tabelas e a atualização de estatísticas das tabelas.   select banner from v$version where rownum &amp;lt; 2; resultado:  Oracle...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&lt;br /&gt;
== Versão do Oracle ==&lt;br /&gt;
&lt;br /&gt;
Verificando as maiores tabelas e a atualização de estatísticas das tabelas.&lt;br /&gt;
&lt;br /&gt;
 select banner from v$version where rownum &amp;lt; 2;&lt;br /&gt;
resultado:&lt;br /&gt;
 Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production&lt;br /&gt;
&lt;br /&gt;
== Listar Maiores tabelas e atualização de estatísticas ==&lt;br /&gt;
&lt;br /&gt;
Verificando as maiores tabelas e a atualização de estatísticas das tabelas.&lt;br /&gt;
&lt;br /&gt;
 select table_name, round((num_rows*avg_row_len)/1048576) tbsize, num_rows, last_analyzed&lt;br /&gt;
 from all_tables&lt;br /&gt;
 where owner=&amp;#039;MAX&amp;#039; and num_rows&amp;gt;0&lt;br /&gt;
 order by num_rows desc&lt;br /&gt;
&lt;br /&gt;
resultado&lt;br /&gt;
&lt;br /&gt;
 TABLE_NAME             |TBSIZE|NUM_ROWS |LAST_ANALYZED          |&lt;br /&gt;
 -----------------------+------+---------+-----------------------+&lt;br /&gt;
 WOSTATUS               | 28639|319467180|2022-02-10 00:50:25.000|&lt;br /&gt;
 WORKORDER              | 65996|226390056|2022-02-10 08:33:14.000|&lt;br /&gt;
 ...&lt;br /&gt;
&lt;br /&gt;
Mesmo que seu ambiente tenha pouca movimentação, atualizar as estatísticas é fundamental pra um funcionamento do ambiente com qualidade.&lt;br /&gt;
&lt;br /&gt;
== Listar Atualização de estatísticas ==&lt;br /&gt;
&lt;br /&gt;
Verificando a atualização de estatísticas das tabelas.&lt;br /&gt;
&lt;br /&gt;
 select to_char(last_analyzed) as last_a, count(1) as cnt&lt;br /&gt;
 from all_tables&lt;br /&gt;
 where owner=&amp;#039;MAX&amp;#039; and num_rows&amp;gt;0&lt;br /&gt;
 group by to_char(last_analyzed)&lt;br /&gt;
 order by to_char(last_analyzed)&lt;br /&gt;
&lt;br /&gt;
resultado&lt;br /&gt;
&lt;br /&gt;
 LAST_A  |CNT|&lt;br /&gt;
 --------+---+&lt;br /&gt;
 09/02/22|171|&lt;br /&gt;
 10/02/22|395|&lt;br /&gt;
 11/02/22|218|&lt;br /&gt;
 ...&lt;br /&gt;
&lt;br /&gt;
== Ver também ==&lt;br /&gt;
&lt;br /&gt;
*[[Oracle|  Mais Artigos sobre Oracle]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Oracle]]&lt;br /&gt;
[[Category:Databases]]&lt;br /&gt;
[[Category:Tecnologias]]&lt;/div&gt;</summary>
		<author><name>Ebasso</name></author>
	</entry>
</feed>