From: | Peter T Mount <peter(at)retep(dot)org(dot)uk> |
---|---|
To: | Dustin Sallings <dustin(at)spy(dot)net> |
Cc: | "Sergei M(dot) Suntsov" <serge(at)uic(dot)nsu(dot)ru>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: [GENERAL] How can i delete large objects from DB? |
Date: | 1998-08-04 17:36:23 |
Message-ID: | Pine.LNX.3.96.980804183351.7573H-100000@maidast.retep.org.uk |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Mon, 3 Aug 1998, Dustin Sallings wrote:
> > Man page on large objects describes how to create one, from file wit
> > lo_import, etc. But if i want delete row from the table which references
> > large object should I delete large object also? How can it be done ?
>
> Well, BLOBs aren't actually stored *in* tables, but you could do a
> trigger mechanism that says ``if someone deletes something from this table, do
> this'' ...this being, ``lo_unlink(that blob)''
An example of such a trigger is in the current development source (in
contrib/lo).
I'm currently working on a fix for orphaning (which is when a row
containing a reference to a blob is deleted, but the blob remains). I have
a possible solution, but currently cannot test it as postgresql is
currently broken on my machine.
--
Peter T Mount peter(at)retep(dot)org(dot)uk or petermount(at)earthling(dot)net
Main Homepage: http://www.retep.org.uk
PostgreSQL JDBC Faq: http://www.retep.org.uk/postgres
From | Date | Subject | |
---|---|---|---|
Next Message | Peter T Mount | 1998-08-04 17:38:03 | Re: [GENERAL] lo_import() problem |
Previous Message | Krasnow, Greg | 1998-08-04 16:32:39 | float8 type |