You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by Diogo Bastos <ba...@gmail.com> on 2008/02/21 11:28:18 UTC
Enormous file size for an empty table
Good morning,
I've been starting to use Derby only a few weeks ago so I'm still very
"green" on a lot of things concerning it.
One of the problems I've been having so far is that I have a table that is
taking me something like 1.2Gb of hard drive space - but here's the catch:
that table is empty!
Is this normal? Have I probably done something wrong?
I would appreciate if someone could help me out on this.
Thanks in advance,
Diogo
Re: Enormous file size for an empty table
Posted by Narayanan <V....@Sun.COM>.
Sai Pullabhotla wrote:
>
> Did you have a bunch of data in that table/other tables which has now
> been deleted?
>
>
>
> If so, what you are seeing is normal. Derby does not automatically
> reclaim the disk space when data is deleted off the tables. However,
> that disk space is reused when you insert any new data. To reclaim the
> disk space, I believe there is a stored procedure that you can call
> which can be found in the documentation.
>
http://db.apache.org/derby/docs/dev/ref/rrefaltertablecompress.html
http://db.apache.org/derby/docs/dev/ref/rrefproceduresinplacecompress.html
>
>
>
> Sai Pullabhotla
>
> President
>
> jMethods, Inc.
>
> Phone: +1 (402) 408-5753
>
> Fax: +1 (402) 408-6861
>
> www.jMethods.com <http://www.jMethods.com>
>
> ------------------------------------------------------------------------
>
> *From:* Diogo Bastos [mailto:bastos.diogo@gmail.com]
> *Sent:* Thursday, February 21, 2008 4:28 AM
> *To:* derby-user@db.apache.org
> *Subject:* Enormous file size for an empty table
>
>
>
> Good morning,
>
> I've been starting to use Derby only a few weeks ago so I'm still very
> "green" on a lot of things concerning it.
>
> One of the problems I've been having so far is that I have a table
> that is taking me something like 1.2Gb of hard drive space - but
> here's the catch: that table is empty!
>
> Is this normal? Have I probably done something wrong?
>
> I would appreciate if someone could help me out on this.
>
> Thanks in advance,
> Diogo
>
RE: Enormous file size for an empty table
Posted by Sai Pullabhotla <Sa...@jMethods.com>.
Did you have a bunch of data in that table/other tables which has now been
deleted?
If so, what you are seeing is normal. Derby does not automatically reclaim
the disk space when data is deleted off the tables. However, that disk space
is reused when you insert any new data. To reclaim the disk space, I believe
there is a stored procedure that you can call which can be found in the
documentation.
Sai Pullabhotla
President
jMethods, Inc.
Phone: +1 (402) 408-5753
Fax: +1 (402) 408-6861
www.jMethods.com
_____
From: Diogo Bastos [mailto:bastos.diogo@gmail.com]
Sent: Thursday, February 21, 2008 4:28 AM
To: derby-user@db.apache.org
Subject: Enormous file size for an empty table
Good morning,
I've been starting to use Derby only a few weeks ago so I'm still very
"green" on a lot of things concerning it.
One of the problems I've been having so far is that I have a table that is
taking me something like 1.2Gb of hard drive space - but here's the catch:
that table is empty!
Is this normal? Have I probably done something wrong?
I would appreciate if someone could help me out on this.
Thanks in advance,
Diogo