Re: How does "createlang" interact with different schemas?

From: "Sean Davis" <sdavis2(at)mail(dot)nih(dot)gov>
To: "P Kapat" <kap4lin(at)gmail(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: How does "createlang" interact with different schemas?
Date: 2009-01-05 13:47:24
Message-ID: 264855a00901050547i7a01d5c3o22ffaa3fb338a80c@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Wed, Dec 31, 2008 at 3:14 PM, P Kapat <kap4lin(at)gmail(dot)com> wrote:

> Hi,
>
> I am not sure if I should be mailing this to postgis list or this one,
> but I'll shoot here first:
>
> Setup: Postgres 8.11 on RedHat EL 5 + postgis 1.3.2
>
> I do the following to add the postgis functionality to a database:
>
> createlang plpgsql dbname
> psql -d dbname -f /usr/share/pgsql/contrib/lwpostgis.sql
> psql -d dbname -f /usr/share/pgsql/contrib/spatial_ref_sys.sql
>
> This adds a bunch of functions and 2 tables to the public schema of
> dbname. Later I add a schema to this dbname database. Will all these
> postgis functions be available to the new schema? What about the 2
> tables (geometry_columns and spatial_ref_sys)? How do these interact -
> are they schema specific or accessible across different schemas in the
> same database?
>

There is no such concept as "accessing from another schema". You grant
users access to whatever in the database you like using "grant" constructs.
If your search_path does not include the schema that holds the function,
table, etc., then you may have to adopt the "schema.table" notation. See
the documentation for information about "GRANT" and schemas.

>
> Now I'll have to admit that I do not know how postgres is setup
> structurally, that is to say, what are schema, tablespace, catalogs,
> domains, procedures,..... and hence the question to this list.
>
> I have a bigger issue currently, but that will be in another mail.
>
> --
> Regards
> PK
> --------------------------------------
> http://counter.li.org #402424
>
> --
> Sent via pgsql-novice mailing list (pgsql-novice(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-novice
>

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Oliveiros Cristina 2009-01-05 16:36:42 db encoding
Previous Message David Gardner 2009-01-04 06:44:09 Re: Optimization support