You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by Kathey Marsden <km...@sbcglobal.net> on 2009/03/26 18:51:34 UTC

behavior of update statistics on empty table

This is kind of an edge case, but I wonder, what should be the behavior 
of update statistics on an empty table if it had previously created 
statistics.

The current behavior seems to be that it leaves the old statistics 
values in sys.sysstatistics.  Is that correct? It seems to me it should 
drop the statistics information in this case.

Thanks

Kathey


Re: behavior of update statistics on empty table

Posted by Kathey Marsden <km...@sbcglobal.net>.
Mike Matrigali wrote:
> The old behavior seems ok to me.
Great. Thanks Mike.



Re: behavior of update statistics on empty table

Posted by Mike Matrigali <mi...@sbcglobal.net>.
The old behavior seems ok to me.  The current info at least reflected
what the actual stats were at some time, which seems more likely to
reflect the future stats than an out of blue estimate by the optimizer
if the stats are deleted.

/mikem

Kathey Marsden wrote:
> This is kind of an edge case, but I wonder, what should be the behavior 
> of update statistics on an empty table if it had previously created 
> statistics.
> 
> The current behavior seems to be that it leaves the old statistics 
> values in sys.sysstatistics.  Is that correct? It seems to me it should 
> drop the statistics information in this case.
> 
> Thanks
> 
> Kathey
> 
>