Re: Patch to fix search_path defencies with pg_bench - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Patch to fix search_path defencies with pg_bench
Date
Msg-id 14219.1241564871@sss.pgh.pa.us
Whole thread Raw
In response to Patch to fix search_path defencies with pg_bench  ("Joshua D. Drake" <jd@commandprompt.com>)
Responses Re: Patch to fix search_path defencies with pg_bench  (Greg Smith <gsmith@gregsmith.com>)
List pgsql-hackers
"Joshua D. Drake" <jd@commandprompt.com> writes:
> I have been doing some testing with pgbench and I realized that it
> forces the use of public as its search_path. This is bad if:

> * You want to run multiple pgbench instances within the same database
> * You don't want to use public (for whatever reason)

> This patch removes that ability and thus will defer to the default
> search_path for the connecting user.

Hmm.  The search_path setting seems to have been added here
http://archives.postgresql.org/pgsql-committers/2002-10/msg00118.php
http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/contrib/pgbench/pgbench.c.diff?r1=1.20;r2=1.21

as part of a mass patch to make everything in contrib work in the public
schema.  I agree that it probably wasn't considered carefully whether
pg_bench should do that; but does anyone see a reason not to change it?
        regards, tom lane


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Wrong stats for empty tables
Next
From: "Kevin Grittner"
Date:
Subject: Re: Serializable Isolation without blocking