Re: [GENERAL] BLOBs
Peter Mount <peter@retep.org.uk>
From: Peter T Mount <peter@retep.org.uk>
To: Dustin Sallings <dustin@spy.net>
Cc: PostgreSQL General Questions List <pgsql-general@postgresql.org>, PostgreSQL Hackers List <hackers@postgresql.org>
Date: 1998-07-25T11:38:41Z
Lists: pgsql-hackers
[moved this to the hackers list] On Thu, 23 Jul 1998, Dustin Sallings wrote: > > Hey, I never saw a follow-up on any of the BLOB questions, so I thought > I'd throw them in here again: > > Is there a way to actually *delete* a BLOB? the lo_unlink() function will delete the blob given it's oid. > Is anyone working on BLOBs? I'm working on the blob orphaning problem that exists for JDBC & ODBC. > Last time I tried to use it, it seemed to store each BLOB in a file by > itself (two files?) in the middle of my data directory, which seems like a very > bad thing IMO. The current scheme actually creates a table and index pair for each blob, which is what you are seeing. There was talk of having another storage manager which stores all of them in a single file, but nothing happened with it. > I also couldn't find any documented way of removing them, and > simply deleting the file(s) caused my vacuum to fail. I'd really like to use > BLOBs instead of nasty MIME encoding of large images, but I'd definitely need > to be able to delete, and it'd be nice if I wouldn't fill up that one directory > with them. If nobody is working on BLOBs, it might be fun to find a way to > implement another storage mechanism, possibly a single file (group of files) to > store the BLOB, or a directory hierarchy. Take a look at the ImageViewer example in the src/interfaces/jdbc/examples directory. Ok, it's in java, but it does show how to store, retrieve and delete images from a database. -- Peter T Mount peter@retep.org.uk or petermount@earthling.net Main Homepage: http://www.retep.org.uk ************ Someday I may rebuild this signature completely ;-) ************ Work Homepage: http://www.maidstone.gov.uk Work EMail: peter@maidstone.gov.uk