Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

Go Back  dBforums > Database Server Software > Oracle > how to create table statistics without histograms

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-03-03, 13:03
tal_olier tal_olier is offline
Registered User
 
Join Date: Aug 2002
Location: IL
Posts: 73
how to create table statistics without histograms

Hi,

We have a strange case at a customer site that his Oracle rewrite queries that hangs if we collect statistics on a table.
In order to disable rewrite (query_rewrite_enabled already set to false) I have deleted the table histograms using the ANALYZE table DELETE STATISTICS and the re-write stopped.

We can verify that histograms data is created using the following query:
SELECT TABLE_NAME,COLUMN_NAME FROM DBA_HISTOGRAMS WHERE TABLE_NAME ='<table_name>';

I tried using ANALYZE command or DBMS_STATS package (compute or estimate) in various options but both have created histograms data all the time.

I have tried looking in Oracle docs but found not syntax to disable the histogram data collection.

Is there a way to do it?
Idea anyone?

Thanks in advanced,

Tal (otal@mercury.co.il).
Reply With Quote
  #2 (permalink)  
Old 09-22-03, 11:49
evanhattem evanhattem is offline
Registered User
 
Join Date: Sep 2003
Location: The Netherlands
Posts: 311
Hi,

for as far as I know, collecting statistics always result in at least 1 histogram per table / index. There's no way to avoid this.
Seems like you have trouble using the Cost Based Optimizer.
Did you try to avoid the CBO by changing to the rule based optimizer? Or is your db version too high (9i)?

Other wise i think it's time to contact oracle about this.

Edwin
Reply With Quote
  #3 (permalink)  
Old 09-22-03, 12:05
AlanP AlanP is offline
Registered User
 
Join Date: Mar 2002
Location: Reading, UK
Posts: 1,098
You could also try the norewrite hint which may disable rewrite if you have access to the sql.

Alan
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On