pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedlarge object unlinking
4+ messages / 2 participants
[nested] [flat]
* large object unlinking
@ 2006-02-23 07:54 sandhya <sandhyar@amiindia.co.in>
0 siblings, 1 reply; 4+ messages in thread
From: sandhya @ 2006-02-23 07:54 UTC (permalink / raw)
To: pgsql-admin; +Cc: sandhya <sandhyar@amiindia.co.in>
hi...
Is there any possibility to delete /Unlink a group of large objects at a time?
Please tell me .To test my application i have loaded somany files into database.Now i want to unlink all those objects.
Please help me in doing this.......
Thanks,
Sandhya
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: large object unlinking
@ 2006-02-23 15:28 Michael Fuhr <mike@fuhr.org>
parent: sandhya <sandhyar@amiindia.co.in>
0 siblings, 1 reply; 4+ messages in thread
From: Michael Fuhr @ 2006-02-23 15:28 UTC (permalink / raw)
To: sandhya <sandhyar@amiindia.co.in>; +Cc: pgsql-admin
On Thu, Feb 23, 2006 at 01:24:43PM +0530, sandhya wrote:
> Is there any possibility to delete /Unlink a group of large objects at a time?
> Please tell me .To test my application i have loaded somany files into database.
> Now i want to unlink all those objects.
You could call lo_unlink() in a query. Example:
SELECT lo_unlink(loid) FROM (SELECT DISTINCT loid FROM foo) AS s;
See also contrib/vacuumlo, which will automatically remove large
objects that aren't referenced anywhere.
--
Michael Fuhr
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: large object unlinking
@ 2006-02-24 06:27 sandhya <sandhyar@amiindia.co.in>
parent: Michael Fuhr <mike@fuhr.org>
0 siblings, 1 reply; 4+ messages in thread
From: sandhya @ 2006-02-24 06:27 UTC (permalink / raw)
To: Michael Fuhr <mike@fuhr.org>; +Cc: pgsql-admin
Thank You Fuhr.
In select lo_unlink(objid) from (select distinct objid from filetbl)AS s;
the above query what is that 'S' stands for in AS 'S'
Can u pls explain me.....
----- Original Message -----
From: "Michael Fuhr" <mike@fuhr.org>
To: "sandhya" <sandhyar@amiindia.co.in>
Cc: "Postgres" <pgsql-admin@postgresql.org>
Sent: Thursday, February 23, 2006 8:58 PM
Subject: Re: [ADMIN] large object unlinking
> On Thu, Feb 23, 2006 at 01:24:43PM +0530, sandhya wrote:
> > Is there any possibility to delete /Unlink a group of large objects at
a time?
> > Please tell me .To test my application i have loaded somany files into
database.
> > Now i want to unlink all those objects.
>
> You could call lo_unlink() in a query. Example:
>
> SELECT lo_unlink(loid) FROM (SELECT DISTINCT loid FROM foo) AS s;
>
> See also contrib/vacuumlo, which will automatically remove large
> objects that aren't referenced anywhere.
>
> --
> Michael Fuhr
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: explain analyze is your friend
>
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: large object unlinking
@ 2006-02-24 07:14 Michael Fuhr <mike@fuhr.org>
parent: sandhya <sandhyar@amiindia.co.in>
0 siblings, 0 replies; 4+ messages in thread
From: Michael Fuhr @ 2006-02-24 07:14 UTC (permalink / raw)
To: sandhya <sandhyar@amiindia.co.in>; +Cc: pgsql-admin
On Fri, Feb 24, 2006 at 11:57:57AM +0530, sandhya wrote:
> In select lo_unlink(objid) from (select distinct objid from filetbl)AS s;
> the above query what is that 'S' stands for in AS 'S'
"s" is a table alias, which is required for a subquery. The choice
of "s" is arbitrary; it can be any valid label.
http://www.postgresql.org/docs/8.1/interactive/queries-table-expressions.html#QUERIES-SUBQUERIES
--
Michael Fuhr
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2006-02-24 07:14 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-02-23 07:54 large object unlinking sandhya <sandhyar@amiindia.co.in>
2006-02-23 15:28 ` Michael Fuhr <mike@fuhr.org>
2006-02-24 06:27 ` sandhya <sandhyar@amiindia.co.in>
2006-02-24 07:14 ` Michael Fuhr <mike@fuhr.org>
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