Inaccurate statistics calculated by the task of automatic statistics collection

Hello

I have a table with about 300,000 sets and I manually collected statistics for the table and its index with the command: "EXEC DBMS_STATS.gather_table_stats ('SCOTT', 'Table_test');" Both indices of the table statistics were accurate and the execution of SQL statements were also very powerful. Then, during the night Enterprise Manager recalculated statistics again, but the results were far from exact:

OWNER: SCOTT
INDEX_NAME: I_TEST_INDEX
INDEX_TYPE: NORMAL
TABLE_OWNER: SCOTT
TABLE_NAME: TEST_TABLE
TABLE_TYPE: TABLE
UNIQUENESS: UNIQUE
COMPRESSION: DISABLED
PREFIX_LENGTH:
NOM_TABLESPACE: USERS
INI_TRANS: 2
MAX_TRANS: 255
INITIAL_EXTENT: 65536
NEXT_EXTENT:
MIN_EXTENTS: 1
MAX_EXTENTS: 2147483645
PCT_INCREASE:
PCT_THRESHOLD:
INCLUDE_COLUMN:
FREELISTS:
FREELIST_GROUPS:
PCT_FREE: 10
LOGGING: YES
BLEVEL: 2
LEAF_BLOCKS: 16
DISTINCT_KEYS: 141
AVG_LEAF_BLOCKS_PER_KEY: 1
AVG_DATA_BLOCKS_PER_KEY: 1
CLUSTERING_FACTOR: 19
STATUS: VALID
NUM_ROWS: 141
SAMPLE_SIZE: 141
LAST_ANALYZED: November 4, 2008 22:03
DEGREE: 1
INSTANCES: 1
PARTITIONED: NO.
TEMPORARY: N
GENERATED: N
SCHOOL: N
USER_TABLES: DEFAULT
USER_STATS: NO.
DURATION:
PCT_DIRECT_ACCESS: 100
ITYP_OWNER:
ITYP_NAME:
PARAMETERS:
GLOBAL_STATS: YES
DOMIDX_STATUS:
DOMIDX_OPSTATUS:
FUNCIDX_STATUS:
JOIN_INDEX: NO.
IOT_REDUNDANT_PKEY_ELIM: NO.
ELIMINATED: NO.


The new statistics report that there are only 141 separate in the table key although there are actually 300 000. The result is that SQL statements executing degrades considerably. Does anyone know why the statistics have become so inaccurate? I'm on 10.2.0.1.0.

Kind regards
Swear

user633661 wrote:
The only thing I'm not sure of is if I should include the statistics calculation step in the batch (this is a PL/SQL procedure) - I mean, it's a mixture of normal practices code that calculates statistics with business logic code?

Swear,

I think Justin has responded to this already pretty well, it is quite common in environments of warehouses of data or any other leads batch environments. You must be precise (or let's say representative) statistics if you want the CBO to do a good job.

BTW, do you know if the collection of statistics on an Index organized table is somewhat different that gather on heap-organized tables?

No, there is no difference. DBMS_STATS (and even surprisingly ANALYZE) know IOT and collect 'table', column and potential segments of infinity and the (mandatory) primary key index (representing the IOT) even if you do not specify a "cascade-online true" in the call DBMS_STATS.

Kind regards
Randolf

Oracle related blog stuff:
http://Oracle-Randolf.blogspot.com/

SQLTools ++ for Oracle (Open source Oracle GUI for Windows):
http://www.sqltools-plusplus.org:7676 /.
http://sourceforge.NET/projects/SQLT-pp/

Tags: Database

Similar Questions

  • How to program using the Task Manager automatic restore Points?


    Hello

    Restore points are created automatically every day, and just before the events significant system, such as installing a program or device driver. There is no need for schedule you a task for her through Task Scheduler. However, you can also create a manually restore point.

    1. Go to control panel of control-> system and maintenance-> system

    2. In the left pane, click System Protection. If you are prompted for an administrator password or a confirmation, type the password or provide confirmation.

    3. Click the System Protection tab and then click on create.

    4. In the System Protection dialog box, type a description, and then click on create.

    Hope this helps

    If this post can help solve your problem, please click the 'Mark as answer' or 'Useful' at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • Get the player starts automatically with Task Scheduler

    Hello

    I don't believe this, or a similar one, the question was asked, so I hope I'm not repeating another thread :)

    I would like to program iTunes (or potentially any multimedia player) to start playing automatically every morning and mix all my music or a playlist - in other words I don't want to hear a song over and over again.

    I tried to implement a task in the Task Scheduler tasks and at the agreed time, the computer sounds like its trying to do something, the blue (instead of the classic mouse pointer) circle appears, but then nothing... though the Scheduler runs the task.

    I have a computer Dell laptop, Inspiron and Windows 8... would be great to do this work, any help is appreciated!

    Thanks in advance!

    This will vary depending on the media player program to use.  But the General method to do this is to set up a scheduled task that starts the program of the media player (.exe file) and also specifies what playlist to play.

    With Windows Media Player, it would look like this in the Task Scheduler (you can test the command by pressing on +R and put it in the box run).

    "%ProgramFiles% (x 86) %\Windows Media Player\wmplayer.exe" /play "c:\users\shawn\music\Playlists\MorningList.wpl".

    Note that this entire command on one line (it does not fit everything on this Web page).  Obviously, you'll need to adjust the location of the saved playlist file.

  • Realizing automatic calculation in the form field Oracle Apex.

    Hi all

    I m facing a problem in my Apex Application.

    I have three ActualAmt, CommAmount, and Comm % fields in my form.

    My requirement is when % ActualAmt and Comm is entered then automatically CommAmount should be calculated on the basis of ActualAmt and Comm %, in the second case, when I enter ActualAmt and CommAmount Comm % should be calculated on the basis ActualAmt and Comm %.

    I have included my formula in Post calculation calculation but does not.


    Please help find the solution.


    Concerning

    Thanks, Mindmap, it worked.

  • Automate the tasks of Mirage

    Hi guys,.

    you know a way to automate the tasks of Mirage, in particular:

    -Deploy applications in cardiovascular disease appear in the specific dynamic Collection

    -Trigger the script leaving smart join/Collection

    -Automate the centralization of endpoint, Reboot, suspend, etc..

    Also I'm looking to solve the following tasks:

    -Uninstalling the Mirage, ideally automated applications again

    -Added a smart Collection where the end point is not member of a domain.

    Any help is appreciated.

    Thanks in advance.

    Kind regards

    Velislav

    This is whats currently available:

    How to: automate the tasks of the Horizon Mirage via API and PowerShell & #187; myvirtualcloud.NET

  • Question to automatically generate the task form

    Hi all

    I am new to BPM, I did a small process and after a human task for my user activity, I tried to generate automatically the task form to my activity, Jdeveloper for the name of the new project.

    I have entered the new name & press ok, and then on Jdeveloper goes without doing any thing & stuck?
    Please indicate why I am facing this problem and how to solve it.

    Note: I use the last worm: 11.1.1.5

    Thank you.

    Published by: Oracle itself on June 15, 2011 08:49

    You can do this post on SOA forums.
    This feature works normally, so maybe it's something wrong with your specific task.
    Try to run jdev.exe and see if the command line windows displays all exceptions.

  • Automatic calculation of the budgetary cost

    Hello

    In projects approved oracle budget cost can take hours and hourly resources the calculation of rates based on the employee's employment to manipulate himself to prepare the budget?

    Is it possible to Oracle project? If so, can any 1 help me on the process?

    Thanks in advance much n...

    Hello

    You may want to consider Project Management User Guide, there is a chapter on the budgeting and forecasting.
    This text says:
    You can set budgets and forecasts of projects Oracle to calculate the gross cost, ployez under the burden of costs and revenues for each line in your budget or forecast. Projects Oracle calculates the amounts based on the quantities and amounts that you enter and from the fee that you specify for the costs and income in your budget or the planned rate to plan the scheduling options...
    .
    Note the extended functionality described here is relevant if you enable financial plans and use HTML pages.
    If you use the budgeting forms you will enter the quantity, but need Extension customer Budget to calculate the cost of crude and loaded automatically. You need to develop for these calculations in the extension code.

    Dina

  • Try to get the Scheduler of tasks for automatically running Windows Media Player with a log?

    I did a new task in the Task Scheduler to run wmplayer.exe. The trigger is whenever a user logs on. He gave me a permission error, which I fixed it by checking "do not store the password." Everything remains that I went alone, without anything change it. So, I disconnected and reconnected again to see if wmp would open by itself at startup. There can be no. Any ideas?

    Haha, nevermind, I forgot to restart the computer >. > This is a lesson to all, ALWAYS RESTART you YOUR COMPUTER IF YOU HAVE PROBLEMS. Patches about all ^_^

  • The Oracle optimizer automatic statistical work does not run after full import

    Hi all

    I did a full import in our QA database, import was successful, but GATHER_STATS_JOB does not work after sep 18 2010 if its activation and on demand, I question last_analyzed table to check and confirmed that he has not run after sep18, 2010.

    See below for the output

    OWNER JOB_NAME HIS STATE START_DATE END_DATE LAST_START_DATE NEXT_RUN_D
    ------------ ------------------------------ ----- --------------- ---------- ---------- ------------------- ----------
    SYS TRUE REGULAR GATHER_STATS_JOB 2010-09-18 06:00:02


    Collection of statistics work defined automatic optimizer Oracle

    =======

    SQL > select JOB_NAME, STATUS, OWNER, REQ_START_DATE,.
    TO_CHAR (ACTUAL_START_DATE, ' dd-mm-yyyy HH24:MI:SS) ACTUAL_START_DATE, RUN_DURATION
    of dba_scheduler_job_run_details where
    job_name = order of 'GATHER_STATS_JOB' by ACTUAL_START_DATE asc; 2 3 4

    OWNER JOB_NAME STATUS REQ_START_DATE ACTUAL_START_DATE
    ------------ ------------------------------ ------------ ------------------------------ ------------------------------
    RUN_DURATION
    --------------------
    SYS GATHER_STATS_JOB MANAGED 16/09/2010 22:00
    + 000 00:00:22

    SYS GATHER_STATS_JOB SUCCEEDED 2010-09-17 22:00:02
    + 000 00:00:18

    SYS GATHER_STATS_JOB SUCCEEDED 2010-09-18 06:00:02
    + 000 00:00:26


    What could be the reason for the GATHER_STATS_JOB job does not although his game to automotive

    SQL > select dbms_stats.get_param ('AUTOSTATS_TARGET') of double;

    DBMS_STATS. GET_PARAM ('AUTOSTATS_TARGET')
    ------------------------------------------------------------------------------------------------------------------------
    Auto

    Someone has this kind of experience, please share
    Apprecitate your answers

    Concerning
    SRH

    ? So basically you're saying is if none of the tables are changed then GATHER_STATS_JOB will not work, but I see tables are updated again the task does not run. I did > dba_scheduler_jobs request and the State of employment are true and regular. Please see my previous post on the output

    Am I missing something here, I get some parameters parameters

    So basically you are saying is if none of the tables are changed then GATHER_STATS_JOB will not work.

    GATHER_STATS_JOB will take place, and if there is no table in which there is a 10% change in the data, it will bring together statistics on this table. If no data in the table have changes less than 10 percent, it will bring together not statistics.

    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14211/stats.htm#i41282

    I hope this helps.

    -André

  • Firefox is running in the Task Manager, but only opens a window.

    I can't get Firefox to open a window. I tried firefox-p (Profile Manager) and firefox-safe (safe mode), but nothing works to open a window. I uninstalled and reinstalled, but that solves nothing. I haven't changed anything recently, so perhaps there is a update (?) Here's what happens:

    I try to start Firefox, and the Task Manager indicates that Firefox is running. It employs about 32 k of memory, but the window never opens.

    I click Firefox again. Manager tasks indicates 2 Firefox process now. The second is to use about 4 k of memory. Running Firefox repeatedly adds additional tasks to Firefox, each using about 4 k of memory.

    After about a minute, the additional tasks of Firefox (the 4 k ones) start closing 1 by 1. I am now down to only 2 Firefox process, using 32 k and 4 k of memory, respectively. As far as I know, these processes will last forever, until I have shut them down manually. If I run Firefox again without closing the current process, it creates another 4 k process, which finally closes itself. If I close all the processes manually, I can start over from scratch. Meanwhile, Firefox never opens a window, or give a clue showing that it is running, with the exception of the processes listed in the Manager tasks.

    bdemmon said

    I deleted the one in my USER folder without change. There are a couple more in various C:\Mozilla\Firefox\Profiles files, so I deleted those too, without change.

    It's a custom location. Normally, the profiles are under AppData\Roaming, I think you already know. There is a shortcut:

    %APPDATA%\Mozilla\Firefox\
    

    This folder must contain a profiles.ini file (.ini file extension may be hidden), which shows the names and paths to your profile folder (s). If you check in a text editor such as Notepad, this file contains sound data?

    If this started right after an update, it could be a problem with security software, put an end to the commissioning (rules of program control) or program files has been corrupted.

    You can check your firewall and other security software for program restrictions.

    To meet possible corrupt files, I suggest:

    Clean reinstall it

    We use this name, but it isn't about deleting your settings, this is to ensure that the program, files are clean (no incompatible or exotic code files). As described below, this process does not disrupt your existing settings. Don't uninstall NOT Firefox, that does not need.

    (A) download a fresh Installer for Firefox 43.0 https://www.mozilla.org/firefox/all/ in an ideal location. (Scroll down your preferred language).

    (B) the release of Firefox (if any).

    (C) to rename the folder of the program as follows:

    (Windows 64-bit folder names)

    C:\Program Files (x86)\Mozilla Firefox
    

    TO

    C:\Program Files (x86)\OldFirefox
    

    (Windows 32-bit folder names)

    C:\Program Files\Mozilla Firefox
    

    TO

    C:\Program Files\OldFirefox
    

    (D) to run the installation program that you downloaded in step (A). It should automatically connect to your existing settings.

    A cleanly reinstalled Firefox starts up normally?

    Note: Some plugins can only exist in this OldFirefox file. If it is missing something essential, present in these files:

    • \OldFirefox\Plugins
    • \OldFirefox\browser\plugins
  • 29 Firefox fails to come out properly and continues to run in the Task Manager.

    It is a continuation of a thread found here:
    https://support.mozilla.org/en-US/questions/997448 by Compumind.

    I pointed out that I had the same experience, especially at the opening of the email links in Thunderbird. I reported also that forced me to go back to 28 FF.

    Moses responded by top wire and suggested:
    (1) download a fresh installer of https://www.mozilla.org/firefox/all/ in an ideal location. (Scroll down your preferred language).

    (2) the release of Firefox.

    (3) rename the folder

    C:\Program Files (x 86) \Mozilla Firefox

    TO

    C:\Program Files (x 86) \OldFirefox

    (4) run the installer you downloaded in the #1. It should automatically connect to your existing settings.

    I followed these instructions carefully but no joy. When installing 29 FF, not only refused to leave (using "exit") and continue to run in the Task Manager up until I killed him after the opening of links in Thunderbird, but I find that he refused to come out after a simple navigation and links.

    Moses had asked that I didn't answer in the original thread, so I re-post here.

    In my view, that there is a serious bug. With Firefox 28... no problem don't except a minor that I have indicated here:
    https://Bugzilla.Mozilla.org/show_bug.cgi?id=1002089

    Yet once I am obliged to 28 FF, although I miss the nice interface and security patches, I need to have a browser that works properly. My wife never even saw the Manager of the tasks before so that's the problem.

    In addition, "guesses" made with this post, the only other thing usual outside that I do, is to have a security policy about cookies (accept by default... I make exceptions for cookies I want to keep and have several that are "allow only for the session.") I also FF the value delete history of navigation at the exit, but that takes a fraction of a second.

    I look forward to when this matter can be addressed successfully and I am able to use 29 FF (and out properly... I can't wait for my wife to follow all of these instructions and it often close manually in the Manager of tasks... or what I want to do this.)

    Good luck for all Mozilla projects. Having installed 29 FF twice and then back return 28 twice, I'll wait and see how this plays out. Please don't send me the standard "start in safe mode", 'restart with disabled modules', 'reset Firefox' stuff (the last time that completely destroyed my browser). I don't think that is what is happening.

    Moses added that there is a problem with the e-mail notifications passing by, so take your time, friends.

    I think now (temporarily) this bug or problem has its roots in "history leaving Compensation."

    I made the leap after a few game with 29 PortableFirefox and reading the blog post linked here:

    [https://support.mozilla.org/en-US/que.../997918#answer-566755]

    .. .and installed 29 FF on my previous FF28 on my box. I unchecked the "clear history on exit" which was only to delete my history, not cookies or anything else, cor - el. My setting should not accept cookies unless I make an exception. Until the FF developers find a way to do this is functional, I'll just have to manually delete the history.

    Furthermore, John99, you want to maybe privacy.sanitize.sanitizeOnShutdown set to 'False', not 'true' If you want to stop the automatic deletion of the history at the exit (attempt).

    I've been running for about 6 hours. without experiencing the bug 'suspended '. So, I can live with that for now until this bug is fixed. It should be fixed... browsers are supposed to be able to do things like that.

    On the other hand, I could find things go wrong... but so far I'm not having a problem.

    I for several hours and will let you know later if things change.

    Kind regards

    Axis

  • How to clear the output buffer, possibly resize and burn again, before you begin the task of output

    I use PyDAQmx with a USB-6363, but I think the question is generic to DAQmx.

    I have an output buffer that I want to be able to (re) write to without starting the task output.

    More specifically, I have a graphical interface and a few sliders, the user can move.  Whenever the slider changes, a new set of values is loaded into the buffer output through DAQmxWriteAnalogF64.  After you set the value, the user can click on a button and start the task output.

    In some cases the change in cursor does not require a change in buffer size, only a change in the data.  In this case, I get the compalint following DAQmx as they tried writing:

    The generation is not yet started, and not enough space is available in the buffer.

    Set a larger buffer, or start the generation before writing data more than content in the buffer.
    Property: DAQmx_Write_RelativeTo
    Value: DAQmx_Val_CurrWritePos
    Property: DAQmx_Write_Offset
    Corresponding value: 0
    Property: DAQmx_Buf_Output_BufSize
    Corresponding value: 92

    In other cases the change in cursor requires both change in the size of the buffer and data modification.  In this case, I get the following, but only after that do a few times each time increase the size of the writing.

    DAQmx writing failed because a previous writing DAQmx configured automatically the size of output buffer. The size of the buffer is equal the number of samples written by channel, so no additional data can be written before the original task.

    Start the generation of before the second writing DAQmx or set true in all instances of writing DAQmx Auto Start. To gradually write to the buffer before starting the task, call DAQmx Configure an output buffer before the first writing DAQmx.
    Task name: _unnamedTask<0>

    State code:-200547
    function DAQmxWriteAnalogF64

    I tried to configure the output via DAQmxCfgOutputBuffer buffer (in some cases, by setting it to zero or a samples, then save again, in an attempt to clear it) but that doesn't seem to do the trick.

    Of course, I can work around the problem by loading data only when the user clicks the end button, but not what I'm asking here.

    Is it possible to "remake" the writing of output before you begin the task?

    Thank you

    Michael

    Today I have no material practical to validate, but try unreserving task before writing the new buffer:

    DAQmxTaskControl (taskHandle, DAQmx_Val_Task_Unreserve);

    With a simulated device, he made the error go away in case the buffer is the same size.  You will need to validate if the data are in fact correct, but I think it should be (unreserving I would say reset the write pointer so the old buffer are replaced with the new data).

    I always get errors when you try to change the size of buffer if (on my 6351 simulated).  I posted some similar mistakes about the reconfiguration of the tasks here, I guess it is possible that this issue has also been set at 9.8 (I always use 9.7.5 on this computer).  If the behavior is still present in the new driver, and also appears on real hardware (not just simulated), then it seems that this is a bug of DAQmx someone at OR should be considered.

    I wrote a simple LabVIEW VI that captures the error in order to help people to NOT reproduce it:

    The best solution at the moment would be likely to re-create the task if you need to change the size of the buffer (or avoid writing data until you are sure what will be the size of buffer).

    Best regards

  • What are the tasks we can perform by using Component Services in the Microsoft Management Console?

    Original title: use MMC

    Can someone enlighten me on component services, found in the administrative tools, including the management console folder. Is their anything that can be done by someone who has no knowledge on this subject, extensive Windows, I use XP (SP3) thank you.

    Hi ratchet.

    Microsoft Management Console (MMC) lets system administrators create much more flexible user interfaces and customize administration tools.

    See this link for the tasks that we can perform using Component Services in the Microsoft Management console.

    With Component Services, administrators can deploy and administer service applications of components through a graphical user interface or automate administrative tasks using a programming or scripting language. Software developers can use Component Services to visually configure routine component and behavior of the application, such as security and participation in transactions, and to integrate components into Component Services applications.

    http://www.Microsoft.com/resources/documentation/Windows/XP/all/proddocs/en-us/snap_start_mmc.mspx?mfr=true

    Also check out this link:

    Using the Microsoft Management Console:

    http://www.Microsoft.com/resources/documentation/Windows/XP/all/proddocs/en-us/snap_start_mmc.mspx?mfr=true

  • The start menu and the task balk disappeared

    On my windows XP the task and menu balk start screen disappeared as a result of a mouse click. "Just the icons on the side right.<" remained.="" what="" should="" i="" do="" to="" get="" the="" balk="" back?="" any="" help="" will="" be="">

    Hi janavasiljev,
     
    This problem can occur for the following reasons:
    • Auto-hide the taskbar has been selected for the taskbar and Start Menu Properties.
    • Your user account settings are corrupt.
    • The core files are damaged.
    • The Explorer.exe file does not load at startup.

    Make sure that the hide option automatically is not selected for the taskbar and Start Menu Properties.

    To determine if the hide option automatically is not enabled for the taskbar and Start Menu properties, follow these steps:

    a. press CTRL + ESC.

    b. If the Start menu is displayed, click on the Start menu and then click Properties.

    c. click on the task bar , clear the Auto-hide the taskbar option and then click OK.

    For more information, see:

  • White screen on Windows Vista Start-cannot open all programs, even the Task Manager

    Original title: white screen on startup of Windows Vista

    Hello

    I tried tirelessly fix my Sony Vaio computer that is running Windows Vista. After that I entered my password by logging into my account, the screen charge nothing; It is empty. I'm unable to open all programs, even the Task Manager.

    I AM able to start safe mode. I tried MSCONFIG, removing all the programs of cleaning, power off start up programs, but nothing seems to work. Can anyone help? Thank you.

    Hello

    See if that helps you.

    Do a Safe Mode system restore to before the problem started.

    http://bertk.MVPs.org/html/restoresysv.html

    @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

    If it doesn't, try a startup repair and / or a system restore using a DVD of Vista from Microsoft

    Manufacturers recovery disks normally do not have Service Options; they are normally a relocation to the factory only settings option.

    Here is the guide to repair Options using a Vista DVD from Microsoft.

    If a friend or a work acquantance of yours has one, you can borrow and use it for repairs.

    http://www.bleepingcomputer.com/tutorials/repair-Windows-with-Windows-Startup-Repair/

    Table of contents

    1. Overview of Windows Vista repair options
    2. How to perform an automatic repair of Windows Vista using Startup Repair
    3. Advanced Tools Overview
    4. Conclusion

    If you do not or can not borrow a Microsoft DVD there is a download of a file ISO of Vista Startup Repair available that you can put on a Bootable floppy to make the above startup repair and that the method is recommended by a large number of posters in these Forums.

    Unfortunately, you have to buy it.

    Here is a link to it:

    http://NeoSmart.net/blog/2011/Windows-Recovery-discs-updated-reinstated/

    See you soon.

Maybe you are looking for