Re: BUG #12379: pgbench should hint to pgbench -i - Mailing list pgsql-bugs

From Fabien COELHO
Subject Re: BUG #12379: pgbench should hint to pgbench -i
Date
Msg-id alpine.DEB.2.10.1503080851220.4406@sto
Whole thread Raw
In response to BUG #12379: pgbench should hint to pgbench -i  (mail@bwe.im)
Responses Re: BUG #12379: pgbench should hint to pgbench -i  (Fabien COELHO <coelho@cri.ensmp.fr>)
List pgsql-bugs
> $ pgbench bench -s 90000000 -j 1 -c 10
> ERROR:  relation "pgbench_branches" does not exist
> LINE 1: select count(*) from pgbench_branches
>
> 11:51  MatheusOl$ bwe: You need to run `pgbench -i` first
>
> Why does the error message does not tell me this plainly? :)

Let us be nice to users. Attached is a very small patch which adds a
simple HINT on this initial failure, for submission to the next
commitfest.

  sh> ./pgbench foo
  ERROR:  relation "pgbench_branches" does not exist
  LINE 1: select count(*) from pgbench_branches
                               ^
  HINT: is "foo" the right database? did you initialize first (pgbench -i)?

--
Fabien.

pgsql-bugs by date:

Previous
From: Devrim Gündüz
Date:
Subject: Re: BUG #12830: postgres-9.4 upgrade is missing PGPORT
Next
From: mage@mage.li
Date:
Subject: BUG #12843: pg_dump -O inserts four unwanted lines to the end of the dump