New answers tagged statistics
You cannot run any DML in a logical standby database unless you deactivate, temporary, the guard feature. To overcome you isse you can do: SQL> ALTER DATABASE GUARD NONE; SQL> SELECT GUARD_STATUS FROM V$DATABASE; GUARD_STATUS -------------------- NONE And then run your dbms_stats.
As Remus said, table statistics are stored in the database similar to other objects like tables and indexes. They play a big role in selecting the execution plan, but there are other factors. That being said, SQL Server knows another type of statistics, statistics that give us information about recent behavior. For example the DMVs ...
Addition to what Remus has mentioned, I would suggest you read -- SQL Server Statistics Questions We Were Too Shy to Ask Aarons answer to - Where are Statistics physically stored in SQL Server? UNDERSTANDING SQL SERVER STATISTICS
The buffer pool is a cache of the database. There is never an 'or', things that are in the buffer pool are also in the database, always. And anything read from the database must be, even temporarily, present in the buffer pool. As for the question: statistics are in the database so a backup/restore will preserve the statistics. Note though that ...
At http://sqlserverpedia.com/wiki/Updating_Statistics (good read) there is a query that I don't fully understand, but I converted it into this, below (SQL Server 2005). Output: CREATE STATISTICS [IX_student_2012_1] ON [student_2012] ([student_key]) CREATE STATISTICS [IX_student_2012_2] ON [student_2012] ([dbname], [id]) CREATE STATISTICS ...
Top 50 recent answers are included