Re: Suggested "easy" TODO: pg_dump --from-list - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: Suggested "easy" TODO: pg_dump --from-list
Date
Msg-id 4CED1610.3090304@dunslane.net
Whole thread Raw
In response to Re: Suggested "easy" TODO: pg_dump --from-list  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Suggested "easy" TODO: pg_dump --from-list
List pgsql-hackers

On 11/24/2010 07:29 AM, Robert Haas wrote:
>   As a first attempt at syntax, I might suggest something along the
> lines of "object type: object name", where the types and names might
> look to COMMENT ON for inspiration.
>

pg_dump already uses a list of object types (e.g. as seen in the output 
from pg_restore --list). Let's not invent something new if we don't need 
to. But we'll need more than that. We'll need enough for disambiguation, 
especially for functions which is your stated use case. So, something 
like this might work:
    FUNCTION:myschema.myfunc:integer,text,timestamp with time zone

We could allow the object type to compare case insensitively. For extra 
credit, allow type aliases, and don't require argument types if no 
disambiguation is needed.

cheers

andrew


pgsql-hackers by date:

Previous
From: Itagaki Takahiro
Date:
Subject: Re: Extensions, this time with a patch
Next
From: Robert Haas
Date:
Subject: Re: Suggested "easy" TODO: pg_dump --from-list