Explicitly adding a table to a schema. - Mailing list pgsql-general

From thatsanicehatyouhave@mac.com
Subject Explicitly adding a table to a schema.
Date
Msg-id 39D75214-8059-4E5E-8C6A-FE6B09B3A5EA@mac.com
Whole thread Raw
Responses Re: Explicitly adding a table to a schema.  (Adam Cornett <adam.cornett@gmail.com>)
List pgsql-general
Hi,

I have a database where I wasn't explicitly using schemas when I started it (i.e. everything was simply under
"public").I've since created several schemas and renamed the "public" schema to something else. When I look at the
definitions(in PGAdmin III), the CREATE statement for the old tables look like this: 

CREATE TABLE foo ( ...

whereas for my newer tables the full schema path is there:

CREATE TABLE myschema.bar ( ...

Is there a way that the explicit schema can be added to my older tables? The reason I want to do this is that I'm
havinga problem with external code (SQLAlchemy) when trying to get foreign key information through reflection-- the
tabledoesn't seem to be found. 

Does this even make sense since the tables are definitely in the new schema anyway?

Cheers,
Demitri

pgsql-general by date:

Previous
From: "Ing.Edmundo.Robles.Lopez"
Date:
Subject: psql is too slow to connect
Next
From: Tom Lane
Date:
Subject: Re: Dump Error Message