Issues in setting dbms_stats

Hello, I use oracle9i.

I have two questions when I read this help...

http://download.Oracle.com/docs/CD/B19306_01/AppDev.102/b14258/d_stats.htm#i1036461

I would be grateful if someone could answer my questions.

Question1
=======
Method_opt parameter.

-AUTO: Oracle determines the columns to collect histograms based on the distribution of the data and the workload of the columns.
-SKEWONLY: Oracle determines the columns to collect histograms based on the distribution of data in the columns.

I understand SKEWONLY. In AUTO, determine the column based on the distribution of the data and workload of the columns... What is the workload of the column? It depends on how many executed queries based on this column? How oracle this follow-up?



Question2
======
Method_opt parameter.

Integer SIZE

I think I know, when we specify size 1, then it creates only a bucket. Even if we have more then a distinct value in the column.

We will tell, we have 10 values in a column, if we specify SIZE 5, then it creates only 5 bucket. But we have 10 distinct values... How does in this scenario?

We will tell, we have 5 distinct in a column values, if we specify the SIZE 10, then he creates 10 bucket. But we have 5 distinct values... How does in this scenario?

There is a table called col_usage$ that stores information about the use of columns. The dbms_stats package uses to determine if not a histogram will be gathered on a given column. How it determines whether to collect histograms of data that I do not know exactly.

size 1 means that there is no histogram, as all values are in a simple bucket.

10 distinct values and only 5 buckets, you get the height of the balanced means histograms and you will spread evenly the values sampled in buckets.
You will have a max and min values. The optimizer uses a formula that estimates the selectivity of a range of factors such as the value max min in a bucket, the size of the bucket, the number of values per bucket, and the popularity is of a given value (number of buckets value appears in)

5 distinct values and 10 buckets, give you a frequency histograms. You will have only 5 buckets of each with a value of 1. There is no need to have an empty bucket. Frequency histograms are more accurate that the exact number of occurrences of a given value is known. They calculate the selectivity based on the number of occurrences of a value by bucket on the total number of occurrences of all values.

Tags: Database

Similar Questions

  • Issue by setting the alignment

    Hello

    I'm dividing the bottom bar by using the following code, the bottom bar has given as img1 string img2. img2, the issue I'm facing is if the chain is small the img2 and img3 is moved to the left directions based on the length of string. What is the problem below

    HorizontalFieldManager horizontalFieldManager = new HorizontalFieldManager)
    FIELD_BOTTOM | Manager.USE_ALL_WIDTH) {}
    {} public void paint (Graphics graphics)
    graphics.setBackgroundColor (0x316AC5);
    Graphics.Clear;
    Super.Paint (Graphics);
    }
    };
    FadeBitmap bitmap = Bitmap
    .getBitmapResource ("icon_tz_faded_316AC5_35x39.png");
    ClockBitmap bitmap = Bitmap
    .getBitmapResource ("icon_date_picker_white_316AC5_35x39.png");
    TzBitmap bitmap = Bitmap
    .getBitmapResource ("icon_tz_white_316AC5_35x39.png");

    ImageButtonField final unfocus = new ImageButtonField("",)
    Field.FOCUSABLE | FIELD_LEFT, "icon_tz_faded_316AC5_35x39.png."
    "icon_tz_faded_316AC5_35x39.png", 0xFFFFFF);

    final ImageButtonField bitmapField = new ImageButtonField("",)
    Field.FOCUSABLE | ImageButtonField.FIELD_RIGHT,
    "icon_date_picker_white_316AC5_35x39.png,"
    "icon_date_picker_selected_35x39.png", 0xFFFFFF);

    final ImageButtonField bitmapField1 = new ImageButtonField("",)
    Field.FOCUSABLE | ImageButtonField.FIELD_RIGHT,
    "icon_tz_white_316AC5_35x39.png", "icon_tz_selected_35x39.png."
    0xFFFFFF);

    margin = ((Display.getWidth () - (fadeBitmap.getWidth () int
    + clockBitmap.getWidth () + tzBitmap.getWidth () + timezoneTitle
    (((. getWidth())) / 4);

    unfocus.setMargin (0, 3, 0, 0);
    timezoneTitle.setMargin (0, 130, 0, 0);
    bitmapField.setMargin (0, 15, 0, 0);
    bitmapField1.setMargin (0, 0, 0, 0);

    horizontalFieldManager.add (unfocus);
    horizontalFieldManager.add (timezoneTitle);
    horizontalFieldManager.add (bitmapField);
    horizontalFieldManager.add (bitmapField1);

    this.setStatus (horizontalFieldManager);

    Edit - I noticed you wereonly questions about the full blue bar. This is because the HorizontalFieldManagers will not take the space they need in the absence of additional style flags. You want to paint the background of the SeparatedFieldManager, since it is the thing that occupies the entire width. First response continues below...

    This is the code that produces the following output for me. It is the class of the entire screen in my test project... If your output is different, this is probably your ImageButtonField class as this is all the code that I did not. I replaced it with a simple ButtonField.

    public final class MyScreen extends MainScreen
    {
        /**
         * Creates a new MyScreen object
         */
        public MyScreen()
        {
            // Set the displayed title of the screen
            setTitle("MyTitle");
    
            HorizontalFieldManager horizontalFieldManager = new HorizontalFieldManager() {
                public void paint(Graphics graphics) {
                graphics.setBackgroundColor(0x316AC5);
                graphics.clear();
                super.paint(graphics);
                }
                };
                HorizontalFieldManager horizontalFieldManager1= new HorizontalFieldManager() {
                public void paint(Graphics graphics) {
                graphics.setBackgroundColor(0x316AC5);
                graphics.clear();
                super.paint(graphics);
                }
                };
    
                Bitmap fadeBitmap = Bitmap
                .getBitmapResource("icon_tz_faded_316AC5_35x39.png");
                Bitmap clockBitmap = Bitmap
                .getBitmapResource("icon_date_picker_white_316AC5_35x39.png");
                Bitmap tzBitmap = Bitmap
                .getBitmapResource("icon_tz_white_316AC5_35x39.png");
    
                final ButtonField unfocus = new ButtonField("button1",
                Field.FOCUSABLE | FIELD_LEFT);
    
                final ButtonField bitmapField = new ButtonField("button2",
                Field.FOCUSABLE | ButtonField.FIELD_RIGHT);
    
                final ButtonField bitmapField1 = new ButtonField("button3",
                Field.FOCUSABLE | ButtonField.FIELD_RIGHT);
    
                horizontalFieldManager.add(unfocus);
                horizontalFieldManager.add(new LabelField("testTitle"));
                horizontalFieldManager1.add(bitmapField);
                horizontalFieldManager1.add(bitmapField1);
                SeparatedFieldManager jfm=new SeparatedFieldManager(horizontalFieldManager, horizontalFieldManager1);
    
                        VerticalFieldManager test = new VerticalFieldManager();
    
                add(jfm);
        }
    
        public class SeparatedFieldManager extends HorizontalFieldManager
        {
            private Field leftField;
            private Field rightField;
    
            public SeparatedFieldManager( Field lField, Field rField )
            {
                super( USE_ALL_WIDTH );
    
                leftField = lField;
                add( leftField );
    
                rightField = rField;
                add( rightField );
            }
    
            protected void sublayout( int maxWidth, int maxHeight )
            {
                super.sublayout( maxWidth, maxHeight );
    
                int width = getWidth();
    
                if (rightField != null && equals( rightField.getManager() ))
                {
                    int x = width - rightField.getWidth();
                    int y = 0;
                    setPositionChild( rightField, x, y );
                }
            }
    
            public void paint(Graphics graphics) {
                graphics.setBackgroundColor(0x316AC5);
                graphics.clear();
                super.paint(graphics);
                }
        }
    }
    
  • Bug: Issues in setting 1 microsecond scale-tektronix oscilloscopes

    With the help of tktds7k driver and LabVIEW 2009 by controlling the 7404 tds- as tds oscilloscope oscilloscope 7154.

    When the following code is executed, with the timescale set to 1 microsecond in the horizontal parameters.vi value tktds, there is no change in the instrument and the previous time scale is maintained in the instrument. But if place it during 2 microseconds or lower values as 200 nanoseconds, changes in scale instrument as expected. I hope that this is a bug in the driver. Please someone confirm. Thanks for any explanation.


  • BlackBerry Smartphones issues with setting up e-mail account.

    It sounds simple enough, I had a look at this guide to set up Blackberry Storm email: http://www.611connect.com/howto/amber_how-to-setup-gmail-on-your-blackberry-storm, but my problem is that I don't have an e-mail tab on my Storm in the configuration section.

    How do I configure this?

    Hi, thanks for the help, but I subscribe to the data plan, so it must be something else, or my provider was not me registered for the one I selected...

    very frustrating!

    17/10/09 - if it turns out that my provider had not subscribed me to the plan I chose. GRR.

  • VCAC 6.0.1 issues with setting Active directory on tenants and pointers for install

    Hello

    So I finished the installation of the VCAC 6.0.1 (published on 13-02-14) and all its components in my test harness.  I am able to connect using [email protected] no problem.  I wanted to give my ad 'Domain Admins' group to the default tenant rights.  I ran the test on connectivity to my AD domain successfully and added to the group Admins in the field of infrastructure and tenant administration Articles and updated.  After review of the tenant defaults remained all (I saw problems with AD administrators you do not add save but remove the "alias" solved this problem.)  When I logout of the VCAC and tried to log in using one of my accounts of Member of the domain admin ([email protected]) seems not to authenticate.  I tried to reboot the device identity thinking maybe it was an AD replication or sync problem but no luck.

    I tried to created a second tenant and populated with the same parameters except of course the name of the tenant by default but not having also no luck there either.  Include some screenshots showing the configurations, but it is really strange behavior and don't know if it's just because it is such a release again or I'm doing something wrong... any suggestions on the place where to even try to troubleshoot it would be appreciated.  I even went so far as to restart the 3 servers, thinking it was a synchronization delay or something but still the same issue

    Note aside a few things I learned the hard way on this facility where people run it for the first time

    - Do not install .net 4.5.1 on your server of iaas.  I had to uninstall it and download version 4.5, included in the page install a device vcac https://your-vcac-appliance server: 5480/Installer /.

    -If your tenant administrator accounts save after hitting the update try to remove the name of the alias for your domain as it seemed to solve my problem (and native AD did not work at all for me at least)

    - Found this excellent article of Kendrick Coleman, which is a step by step guide for installation complete... very thanks and well presented.  Also has links to some useful tools like the AD Explorer to help with DN names as well as a PS script to prepare your server, IAAS, which has been a lifeline for http://www.kendrickcoleman.com/index.php/Tech-Blog/how-to-install-vcloud-automation-center-vcac-60-part-1-identity-appliance.html

    Well, what I thought about it.  It turns out that delete and then re-create the identity store for the tenant to vsphere.local (the default when first created), I was finally able to include the correct information to AD, then a final reboot of the environment and I was able to authenticate to AD.  Also for those of you who did not default that there no store identity for the first tenant then please make sure that create you an and save yourself a lot of headaches and frustration :-)

  • Printer HP Inkadvantage 2545 - issue with setting up wireless home: Netgear router

    Recently bought HP Inkadvantage 2545.

    I want to connect to my home network wireless that will allow the mobile and portable on any room in my house feel.

    However, the Netgear router is unable to identify the printer on the network wireless... message "router and the printer are on a different network.

    I tried HP Diagnostics. If the printer appears on the 'list of printers', it is not recognized by the router to connect through the wireless router.

    Hi ADUTT,

    Welcome to the HP Forums!

    I see that you have problems connecting your printer to your Netgear router.

    What operating system you use on your laptop? Windows or Mac? What version?

    In the meantime, I suggest to view this guide. Installation of the software of the printer for a wireless network connection.

    Hope this helps and have a nice day.

  • Issue by setting the value in VO

    Hello
    I'm getting following error highlighting to the VO XxpimRelationshipRulesVO1. are the subject of the VO and FromIccNameTemp the column I'm putting

    I'm inside the AM framework using a loop so much FromIccNameTemp and FromIccName refer to the same database columns.

    rowi.setFromIccNameTemp (rowi.getFromIccName ());

    oracle.jbo.ReadOnlyAttrException: Houston-27008: attribute value for FromIccNameTemp in the object XxpimRelationshipRulesVO1 view failed.

    How to solve this problem.

    Hello

    Check if the VO attribute is updateable in the VO Assistant.

    Thank you
    -Anil

  • Set linesize does not work in sqlplus

    I am trying to use sqlplus to empty a few DOF for a stored procedure. I found a problem with my script where it isn't properly unload the lines in a file, and this seems to be caused by problems with the 'set linesize' command in sqlplus. Lines are getting truncated to 80 characters, no matter what I set the linesize variable to (currently I changed it to 500 as test - but it still doesn't work)!

    For example, I have a line in the procedure as follows:



    CREATE OR REPLACE PROCEDURE
    ...
    INSERT INTO SOME_TABLE_NAME_HERE (OWNER, ACTIVITY, ACTIVITY_COST, NUM_WORKERS, NULL)
    SELECT...


    I can see that the 80th character is the "NULL" and "ULL" is beyond the limit in SQL Developer. When I empty the DDL in sqlplus, it appears like this, no matter what I set linesize to:



    CREATE OR REPLACE PROCEDURE
    ...
    INSERT INTO SOME_TABLE_NAME_HERE (OWNER, ACTIVITY, ACTIVITY_COST, NUM_WORKERS, N
    ULL)
    SELECT...



    Here are the options I use in their entirety. This is an excerpt from a shell script that I'm trying, but you can see the options that echoes in the file that is ultimately read / performed by sqlplus:

    echo "set position off;" > > proc.sql
    echo "set echo off;" > > proc.sql
    echo "value 999 pages;" > > proc.sql
    echo "set off termout;" > > proc.sql
    echo 'long set 90000'; > > proc.sql
    echo ' set linesize 200; "> > proc.sql
    echo "${schema} .txt reel" > > proc.sql
    echo "select dbms_metadata.get_ddl ('PROCEDURE'," ${proc} ") from dual;" > > proc.sql


    No matter what I set linesize she always truncates to the 80th character and begins printing on the next line. Change the linesize option seems only right key to exit with spaces. So if the line is longer than 80 characters and I set linesize to 90, it truncates the 80th character, impression 10 places and then print 'LLD') and 86 seats on the next line. If I change to 100 then I get 20 seats on the first line, followed by "ULL") and 96 places on the next line. And so on...


    I tried to use trimspool ON but it does not help the issue. Set linesize seems to be useless - everything is truncated to 80 characters. What I'm doing wrong here? Thank you!

    Hi and welcome to the forum,

    Looks like you need the LONGCHUNKSIZE of the VALUE

    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14357/ch12040.htm#SQPUG089

    Concerning
    Peter

  • suddenly missing emails password

    What is interesting. My recent emails are missing from my mac and all devices, but receive new emails. I looked at the forums, and a solution was to reset your zone in the preferences, which I've never had to do. It turns out he has been to China, so I opened and return to Seattle, WA. My recent emails are still missing.

    But now in my mail icon, it shows the red dot with 123 in it. Is this proverb I have 123 new emails, that I can't see? How to bring back my old emails. Those that I put in the files is always in the blank files it sews.

    Was, I hacked? That's happened? Thanks for your help.

    Riki

    There has been some reports of people getting their ID compromised through China-based pirates - so I would like to at least change my password Apple ID and put security issues and set two-factor authentication

    That being said - does your email provider has a web portal - (for example Yahoo would be mail.yahoo.com)

    Check here to see if the emails are current.

    The other option is to restore a backup from when you had email assuming that you have a

    Also you lose everything by the date of the backup if you do this

  • X 250 and HDD disappears

    Hi all

    I have random problem with BSOD with Windows 10 X 250 races.

    The BSOD error may vary and is not probably important (Windows encountered problem.., kernel_inpage_error, critical_process_died etc., would not a precise formulation of BSOD). The memory dump is never created, or whatever it is is saved in the windows EventViewer until the next boot.

    I discovered this problem is that system HDD (SAMSUN SSD MZ7LN256HCHP - 000 L 7) gets disconnected (or turned off?) and this causes the BSOD.

    I played with the power option bit and at one point I could simulate the issue with setting in power Option-> "disable the hard disk after." But this does not completely solve the problem. I disabled this option and still get the BSOD at random even on AC. I don't want everything to complete (every power option).

    So before I go contact Lenovo for repair, known someone the similar problem? I think there might be question of motherboard, SATA cable, or disk Samsung SSD.

    I tried the system check Lenovo (bios app) tests of motherboard, hard drive, memory etc. No problem. I tried windows tool to check drive... everything is good. The installation is new (like a week ago I installed Windows 10). Unfortunately I am not the first owner and I don't know if the problem was with Win8.1 also. So it could be a power rating of 10 Windows (although I do not belive it much). I checked that I have all the latest drivers... check on Lenovo side as well as the Intel site.

    So did anyone experienced a similar problem with their X 250? No idea what I could try it too? I would like to exchange the HARD drive, but I'm afraid I might lose the warranty if I opent the laptop?

    I like this laptop, but this 'crazy' (s) me

    Thank you.

    Thanks for the tip.

    I found the reason (probably):

    I changed to another SSD HARD drive and the system worked well. Then I remembered that I forgot something on the original HARD disk and replace the original HARD disk. I let it run for a while (no time to go out again) system and still had no problem since the switch. I also reinstalled OS, tested with different Powerprofile, put a load on the HARD disk or let him sleep... still everything is ok.

    I think that this problem was with cable or contact with SSD or the motherboard.

    I do not notice any issue (cable), so maybe it's something inside the cable. No idea. but it works...

  • Redirect https admin page?

    Hi Forum,

    I installed 6.4.0 without problems.

    However, the admin page is now exposed to the Internet over HTTP, which I see as a potential security risk.

    Is it possible to point the http://somedomain.nl/ to a webshare and point http://somedomain.nl/admin to https://somedomain.nl/admin?

    This will block remote access to admin pages, because HTTPS is not allowed on the router.

    On the internal network, I would still be able to connect to the admin via HTTPS pages.

    Figgered out. Let's say you have created a Web share directory from the Admin page, called "your_webshare_dir".

    VI /etc/frontview/apache/Shares.conf

    Change

    Alias "/ your_webshare_dir" "your_webshare_dir / data / '.

    Options Indexes + includes
    Order allow, deny
    Allow all the
    Options - ExecCGI
    AllowOverride None
    TO:
    AliasMatch "^ / (?). Apps/.*)(.*)$"" / data / your_webshare_dir / $1.

    Options Indexes + includes
    Order allow, deny
    Allow all the
    Options - ExecCGI
    AllowOverride None

    Nothing, except the icons of the apps in the Admin page will redirect to your webshare.

    VI /etc/frontview/apache/http-share-redirect.conf
    RewriteEngine on
    #RewriteRule ^ / $ / admin [R, L]

    This will disable the auto - redirect to the administration page when you go to http://your.domain.com/.

    VI/etc/apache2/sites-available/fv-http-admin

    Include "/ etc/frontview/apache/defaults.conf".
    Include "/ etc/frontview/apache/http-redirect.conf".
    Include "/ etc/frontview/apache/http-share-redirect.conf".
    Include "/ etc/frontview/apache/fv-admin.conf".
    Include "/ etc/frontview/apache/Shares.conf".
    Include "/ etc/frontview/apache/apps-https.conf".
    Include "/ etc/frontview/apache/READYDROP.conf".
    Include "/ etc/frontview/apache/lan-try.conf".

    Make sure that http - redirect.conf is included in the list of configurations.
    (Note: don't know why it's necessary, but it, it works for me.)

    WARNING: Use at your own risk.
    Known issues: these setting changes will be overwritten when you make an update of the firmware.

  • Printer offline

    Hi, I have a printer HP 1512. I moved to my new apartment and I am unable to connect the printer to my new wifi network. It worked perfectly in previous flat using the Wi - Fi connection. Help, please. I need for Mac.

    Thank you

    Hello @ElizabethCh, greetings!

    Thank you access the Forums from HP Support for extra support! It's a good place to find the help you need, other users, HP experts and other support staff.

    I understand that you are facing issues while setting up wireless on your printer Deskjet 1512. I guess that since the network is changed, you must connect your printer to the new network.

    Go to http://hp.care/2egdgBa and scroll down to 'frequently asked questions '. Expand "How do I connect the printer to my network" then expand "Wireless connection (Wi - Fi) to your network" and follow the steps under "replacing a USB connection Wireless in the printer software.

    If you have trouble, let me know and I'll do my best to help.

    See you soon

    Please click on 'acceptable' on the post that solves your problem to help others to find the solution. To show gratitude for my help, please click the 'Thumbs Up icon' below!

  • Problem of g6-2262sa Pavilion computer laptop wifi adapter

    I had the laptop is for a couple of years and I have seen constant statrted - every 20 minutes about) problems adpater wifi from updateing to W8.1.

    I have a factory Ralink 802.11 b/g/n wifi adapater equipped form.

    This forces me to the resolution of the problems of the EU to reset the adapter wifi constantly.

    I followed advice on HP ect forums - delete and re install the driver and nothing has changed.  Now it's bejond one joe - wha else can do?

    Hello

    Ive Uplaoded the drivers but ther as not turns into a performance.  I found a video tech on the power adapter ifi issues that sets to power the maximum performance of ot options that seems to work.  Thank you

  • HP 8620: HP desperation

    People, thank God Costco has an excellent return policy, I gave up my ysterday HP 8610 old of one year after another problem and was refunded, upgrading to a new HP8620. Even made a little money on the transaction.

    But I'm not kidding.

    I spent more than four hours on the phone with HP since I bought the printer yesterday.

    And questions about printing are not always resolved with another call, the team high tomorrow.

    Is this really a record?

    Two calls with the customer support of routine and once with the high team. The guy in the high team told me after 90 minutes, the PC wireless Adapdtor was the issue and sets.  Of course, two hours later, nothing prints again and I need to wait another expert to remind me.

    And in this mixture, tonight, the guy who I spoke told me the HP technicians had hardcoded in the IP, which is a problem as soon as it changes. They did this to try to force a fix.

    Hello and welcome to the HP support community!

    You are wanting help from us, or just a place to vent?

    WyreNut

  • Why are some attributes of 1394 camera Max writable yet Enumerate in LabVIEW Vision as unwritable

    I know that this room sees its fair share of issues of setting attribute camera but I hope that it is sufficiently different to justify an exchange of views.

    I'm in the middle of a piece of code that used to use IMAQ Legacy 1394 to IMAQdX since NEITHER decided to drop the single 1394 support portage.  I ran into an interesting problem.  When you work with a DCAM 1.3 complient camera (Prosilica E1360C, firewire) I find that it is possible to manually set the Max gain, but when you list the attributes of the camera in LabVIEW using the enumeration Attributes.vi, CameraAttributes::Gain: Value rises only not available in writing.  How did MAX OR move it?  I tried to write the gain using the gain writing Register register manually by referencing the DCAM 1.3 Spec document and then using the Register.vi to write, but I had no luck.  The same is true when you're just trying to write the CameraAttributes::Gain: Value by using the attribute writing property node.

    Does anyone have a suggestion?


Maybe you are looking for

  • How can I remove all unwanted without opening?

    My Junk folder has 5 or 6 items in there. Since they are unnecessary, I don't want to open them, I want to just get rid of them. How do I do that?

  • Alternate thumb-scrollbar-webkit-, - webkit-scrollbar-track and - webkit-scroll bar which works fine in chrome and safari

    Here is my code, li.event_list_cnt::-webkit-scrollbar { width: 6px; } ::-webkit-scrollbar-track { background: url('/mma/sites/all/images/home/scroll-bg.png')no-repeat; background-position:center; -webkit-border-radius: 10px; border-radius: 10px; } li

  • I just picked up the box and it won't work!

    Hi, I just received a 23-b190 Pavilion desktop computer, plugged and received a message that says "windows cannot complete the installation.  To install windows on this computer, run the Setup again.  I don't know what to do.  The fan came immediatel

  • 5 GHz Network connect

    Hello My network card supports the N network, but windows cannot find the network. Can someone help me with this problem

  • Local Settings\Temp

    -Properties foilder- Type: File folder Location: C:\Documents and owner Settings\Temp Size:                                                   3.71GB Size on disk: 3.78 GB Contains: 78, 981Files, 380 records Can q. I delete files (Temp folder)? Q. can