Re: Extent Sizing in Online 5.08?
Posted in 1998
Tony Marasco wrote:
> I am hoping someone could help with a few Online questions...
>
> I noticed in dbaccess you can specify the initial and next
> extent sizes when creating tables. I found the results in
> the systables database. How can you set these values from
> within a program? I could not find a command to add to
> "create table" or "create index"...
>
> I read that "ALTER INDEX".."TO CLUSTER" will reclaim deleted
> space. I have a table that had 400K rows deleted and I'd like
> to pack it. In the dbaccess help I could not find this
> command.
alter index fred to clusterwill cluster on index fred
> Is this a 7.x feature (my manual says 5.0?) If I get it to
> work, will the index remain a cluster index?
>
The table gets its rows reordered in the sequence of the index. It's a
one-off operation ; if you delete more rows the table doesn't get the
gaps closed up and new rows can get added out of sequence into the
gaps. If you want to retain the clustering you have to recluster. BTW
you need sufficient free space in the chunk to rebuild the entire table
as clustering constructs the resequenced version and then releases the
space of the old one.
> Finally, in SE there was a program called "bcheck". I am
> aware of "tbcheck" in Online. Is there a way to get tbcheck
> to rebuild all indexes as bcheck does in SE? I could only
> get tbcheck to report extent problems and no critical errors.
>
tbcheck -ci database (or database:table)
It should prompt you before rebuilding. Alternatively add -y to make it
make it rebuild without prompting. You must be in quiescent mode (and
so should the instance ;-) in order to have tbcheck rebuild. You can
achieve the same thing by dropping and rebuilding indexes; this can be
done with the instance online but the table is locked whilst the rebuild
runs.
Ian
> Thanks in advance!