Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3224948
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T16:16:58+00:00 2026-05-17T16:16:58+00:00

I have a Web Application which is based on MapServer, which uses PostGIS as

  • 0

I have a Web Application which is based on MapServer, which uses PostGIS as underlying database extension. Now I want to have a dedicated database role which is used for MapServer, cause I don’t want to access the database via the postgres superuser. This role should only have SELECT permission on public tables (which is easy to achieve) and EXECUTE permissions on public PostGIS functions.

Several questions arise: Are ALL the PostGIS relevant functions stored in the public schema of a database or is there anything else to consider?

How can I extract all the functions information – i.e. function name, number and names of arguments – from the information_schema or the pg_catalog of the database?! I need this information for the GRANT EXECUTE on function(args) to MapServerUser statements!

Thank you in advance!!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T16:16:58+00:00Added an answer on May 17, 2026 at 4:16 pm

    In PostgreSQL 8.4.x:

    SELECT n.nspname as "Schema",
      p.proname as "Name",
      pg_catalog.pg_get_function_result(p.oid) as "Result data type",
      pg_catalog.pg_get_function_arguments(p.oid) as "Argument data types",
    CASE
      WHEN p.proisagg THEN 'agg'
      WHEN p.proiswindow THEN 'window'
      WHEN p.prorettype = 'pg_catalog.trigger'::pg_catalog.regtype THEN 'trigger'
      ELSE 'normal'
    END as "Type"
    FROM pg_catalog.pg_proc p
        LEFT JOIN pg_catalog.pg_namespace n ON n.oid = p.pronamespace
    WHERE pg_catalog.pg_function_is_visible(p.oid)
         AND n.nspname <> 'pg_catalog'
      AND n.nspname <> 'information_schema'
    ORDER BY 1, 2, 4;
    

    Found by running psql with the -E parameter (show hidden queries) and then running the \df command.

    Also, the “public” schema in PostgreSQL is just named that way. It carries no special meaning. It’s a bad name. What you DO need to look out for is the “PUBLIC” role (all caps). While tables are not automatically granted the PUBLIC role, my experience is that PUBLIC automatically gets execute permission on functions defined with SECURITY INVOKER.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a PHP web application which uses a MySQL database for object tagging,
I have created an application (a web-based application) which now has a large number
I have a problem with a little .Net web application which uses the Amazon
We have an intranet asp.net web application which uses the OOTB ASP.net membership and
I have a web-based application which is very highly reliant on jquery / javascript,
I have a web application which will return a user id based on the
I have a web application which connects to an Oracle database. The application is
We have a web application in which the users perform ad-hoc queries based on
I have a PHP based web application which is currently only using one webserver
I have a web based application which server's content to authenticated users by interacting

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.