pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feeddeleting large objects from jdbc
2+ messages / 2 participants
[nested] [flat]
* deleting large objects from jdbc
@ 2001-08-08 05:32 heatherm@famoice.com
0 siblings, 1 reply; 2+ messages in thread
From: heatherm@famoice.com @ 2001-08-08 05:32 UTC (permalink / raw)
To: pgsql-sql
Hi,
I've been browsing the newsgroup archives and came across the following:
> > > > > Can you see a scenario where a programmer would forget to
delete the
> > > > > data from pg_largeobject and the database becoming very large
filled
> > > > > with orphaned large objects?
Does this mean that to delete my large object I need to delete the row
in my table, and also the row or rows in pg_largeobject. Currently I am
only deleting the row in my table. I have just been looking at the
pg_largeobject table, it seems to have more rows than I would expect in
it. Is the solution to pass these two commands to jdbc?
delete from my_table where lob_oid = 1234
delete from pg_largeobject where loid = 1234
Thanks in advance
Heather.
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: [SQL] deleting large objects from jdbc
@ 2001-08-20 01:52 Grant <grant@conprojan.com.au>
parent: heatherm@famoice.com
0 siblings, 0 replies; 2+ messages in thread
From: Grant @ 2001-08-20 01:52 UTC (permalink / raw)
To: pgsql-sql; +Cc: pgsql-admin@postgresql.org
> I've been browsing the newsgroup archives and came across the following:
>
> > > > > > Can you see a scenario where a programmer would forget to
> delete the
> > > > > > data from pg_largeobject and the database becoming very large
> filled
> > > > > > with orphaned large objects?
>
> Does this mean that to delete my large object I need to delete the row
> in my table, and also the row or rows in pg_largeobject. Currently I am
> only deleting the row in my table. I have just been looking at the
> pg_largeobject table, it seems to have more rows than I would expect in
> it. Is the solution to pass these two commands to jdbc?
> delete from my_table where lob_oid = 1234
> delete from pg_largeobject where loid = 1234
Yes or jdbc might have a large object unlink/delete/remove function. I use
PHP and it has a function that will remove the large object for me, but
your solution is just as good imo.
* Another important point to note is that large objects are _not_ backed
up by default.
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2001-08-20 01:52 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-08-08 05:32 deleting large objects from jdbc heatherm@famoice.com
2001-08-20 01:52 ` Grant <grant@conprojan.com.au>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox