[ 
https://issues.apache.org/jira/browse/DERBY-269?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12613458#action_12613458
 ] 

Mamta A. Satoor commented on DERBY-269:
---------------------------------------

I spent time looking through selectivity.sql and tried converting the test 
cases into just a sql file where we do not rely on the old functionality which 
is not supported anymore. The existing selectivity.sql depends on the features 
like Object.methods eg runtimestatistics().rts.getEstimatedRowCount(), 
runtimestatistics().getScanStatisticsText('TEMPLATE') inside of sql. 
eg
create view showstats as
select cast (conglomeratename as varchar(20)) indexname, 
           cast (statistics.toString() as varchar(40)) stats,
           creationtimestamp createtime, 
           colcount ncols
from sys.sysstatistics, sys.sysconglomerates 
where conglomerateid = referenceid;

Such object lookup is not available in Derby. I will spend more time on it but 
it may not work out with the curent Derby functionality.

I was wondering if community had any ideas/test cases which I can use for the 
new stored procedure. I can do basic testing which shows that the stored 
procedure runs etc but it will be nice to see the real impact of running the 
stored procedure on a query before and after the update statistics runs. Thanks 
for any help with this.


> Provide some way to update index cardinality statistics (e.g. reimplement 
> update statistics)
> --------------------------------------------------------------------------------------------
>
>                 Key: DERBY-269
>                 URL: https://issues.apache.org/jira/browse/DERBY-269
>             Project: Derby
>          Issue Type: New Feature
>          Components: SQL
>    Affects Versions: 10.0.2.0, 10.0.2.1, 10.1.1.0, 10.2.2.0, 10.3.1.4
>            Reporter: Stan Bradbury
>            Assignee: Mamta A. Satoor
>         Attachments: DERBY269_update_statistics_svndiff_ver1.txt, 
> DERBY269_update_statistics_svnstat_ver1.txt
>
>
> Performance problems are being reported that can be resolved by updating the 
> cardinality statistics used by the optimizer.  Currently the only time the 
> statistics are guaranteed to be an up-to-date is when the index is first 
> created on a fully populated table.  This is most easily accomplished on an 
> existing table by using the command: 
>    alter table <table-name> compress [sequential]  
> Compress table is an I/O intensive task.  A better way to achieve this would 
> be to re-enable parser support for the 'update statistics' command or 
> re-implement the update in some other fashion.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to