> -Original Message-
> From: Viatcheslav Kalinin [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, July 31, 2007 9:16 AM
> To: Lee Keel
> Cc: pgsql-general@postgresql.org
> Subject: Re: [GENERAL] tables not in list
>
> I usually resolve this as:
> -- this function le
Lee Keel wrote:
Is there no way to do this without doing an insert into another table?
I usually resolve this as:
-- this function lets you select from an array
CREATE OR REPLACE FUNCTION "array_to_set" (vaarray anyarray) RETURNS
SETOF anyelement AS
$body$
BEGIN
FOR I IN COALESCE(ARRAY_LOW
Is there no way to do this without doing an insert into another table?
_
From: paddy carroll [mailto:[EMAIL PROTECTED]
Sent: Monday, July 30, 2007 3:24 PM
To: Lee Keel
Cc: pgsql-general@postgresql.org
Subject: Re: [GENERAL] tables not in list
put all your tables in a new table
put all your tables in a new table (public.tables)
select table_name from public.tables
where public.tables.table_name not in (select table_name from
information_schema.tables where table_catalog='postgres' and
table_type='BASE TABLE' and table_schema='public')
On 30 Jul 2007, at 20:31,
Hi List,
I have a list of table names and I am trying to confirm that they are all in
my postgres db. But what I want returned is a list/array of ones that are
in my list but not in the db. So for example:
CREATE TABLE test
(
somecol integer
) WITHOUT OIDS;
CREATE TABLE bar
(
barcol inte