GnuCash 2.3.x/2.4 PostgreSQL Schema support?

Vinny vinny-mail-01+gnucash20100601 at palaceofretention.ca
Tue Jun 1 20:55:39 EDT 2010


On 05/29/2010 18:56, Anthony Messina wrote:
> Thank you for GnuCash.  I've been using the program reliably since 2007 (with
> Fedora packages and the XML backend).
>
> I've just upgraded to Fedora 13, including GnuCash and have been trying out
> the PostgreSQL backend using Kerberos/GSSAPI login to my server.
>
> I would like to store the GnuCash data in a specific PostgreSQL 'gnucash'
> schema underneath my username, rather than the 'public' schema, something
> like:
>
> +amessina (Database)
> |
> +--+gnucash (Schema)
> |
> +--+public  (Default Public Schema)
> |
> +--+<other schema>...
>
> I cannot seem to figure out how to specify the schema name properly in the
> "Save As" window.
>
> Is what I am looking for possible?  Again, thank you.  -A

A relatively elegant way to do this is to set the
'search_path' for the database username that you are using.

pgAdmin III allows you to set properties on the login roles.
If you set the search path, it will find the gnucash schema
first and use it.

set search_path to gnucash,public;

New tables will be created in the gnucash schema.
Searches for tables (for SQL statements that don't
specify a table's schema using the dot operator),
will start in the gnucash schema and proceed to the
public schema, until the table is found.

Regards,
Vinny


More information about the gnucash-user mailing list