From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | "Simon Shum" <s035668(at)mailserv(dot)cuhk(dot)edu(dot)hk> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Using Large Object in PostgreSQL |
Date: | 2004-06-20 19:23:52 |
Message-ID: | 6644.1087759432@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
"Simon Shum" <s035668(at)mailserv(dot)cuhk(dot)edu(dot)hk> writes:
> I just used oid as a reference to store some binary large object.
> After some time, I find that the data build up to a very large size 3.xx GB=
> but I just have 2 or 3 records with a binary large object inside. So what=
> may be the problem?
> by the way, I just delete the records with oid field using delete from tabl=
> e where id =3D 'xxx'. Will this left a unreferenced copy of large object in=
> side the database?
Yes.
> If yes, what should I do?
contrib/vacuumlo will help you identify the large objects that need to
be removed. After you get done, pg_largeobject will need a VACUUM
FULL.
See also contrib/lo, which is a wrapper datatype that deletes large
objects when you delete the reference. This is probably closer to the
behavior you were expecting.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2004-06-20 19:37:51 | Re: plpgsql - Inserting DEFAULT Value. |
Previous Message | Tom Lane | 2004-06-20 18:25:16 | Re: Postgresql installation. |