Skip site navigation (1) Skip section navigation (2)

About oids

From: Philip Bierhoff <flip(at)win(dot)tue(dot)nl>
To: pgsql-general(at)hub(dot)org
Subject: About oids
Date: 1998-05-23 12:22:19
Message-ID: 199805231222.OAA01363@svstud.win.tue.nl (view raw or flat)
Thread:
Lists: pgsql-general
Hello,

I can't find any documentation on this in manuals and FAQ. I store some
files in a database, which I access through JDBC from a Java application.
Now I want to delete some of these entries. Issuing

 DELETE FROM files 

does only remove the oids from the table, but the file still remains on my
disk (I checked the data/base/ dir and the "xinv" and "xinx" files are
still there.). I did some research and found out that the function 
lo_unlink removes the files. However, the parameter of lo_unlink is an int4,
and not an oid. There is no function to convert oid to int4.

So, can someone tell me how I should implement a (non working) query like
this:

 SELECT lo_unlink(f) FROM files WHERE title = 'test.txt'

Thanks in advance

Philip

Responses

pgsql-general by date

Next:From: The Hermit HackerDate: 1998-05-24 03:41:20
Subject: permissions ..
Previous:From: Bruce MomjianDate: 1998-05-22 14:55:53
Subject: Re: [GENERAL] error messages not only English

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group