From: Angus Berry <angus.berry@elken.com>
To: pgsql-admin@postgresql.org
Subject: query on multiple tables in schema
Date: Tue, 28 Sep 2004 17:19:20 -0400
Message-ID: <1096406359.2215.135.camel@vaio1linux> (raw)
Hi, I wonder if anyone can help.
I'd like to execute a SQL query that performs an action on all the
(unrelated) tables that I select. The following query doesn't work, but
the subselect (which works) shows what I'm trying to do. All tables have
an identical column called id_num.
delete from
(select tablename from pg_tables where schemaname = 'public')
where id_num = null
I'd appreciate any advice.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: angus.berry@elken.com
Subject: Re: query on multiple tables in schema
In-Reply-To: <1096406359.2215.135.camel@vaio1linux>
References: <1096406359.2215.135.camel@vaio1linux>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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