From: Jan Wieck Date: Sat, 27 Sep 2003 19:15:34 +0000 (+0000) Subject: Fixed calculation of bid when generating accounts. Used to create X-Git-Tag: REL9_0_0~14289 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=e9ff025345b53967a8e2143142509a85b10ef621;p=pg-rex%2Fsyncrep.git Fixed calculation of bid when generating accounts. Used to create accounts.bid values of zero. Jan --- diff --git a/contrib/pgbench/pgbench.c b/contrib/pgbench/pgbench.c index ede1b02f6f..94e79ba021 100644 --- a/contrib/pgbench/pgbench.c +++ b/contrib/pgbench/pgbench.c @@ -1,5 +1,5 @@ /* - * $Header: /cvsroot/pgsql/contrib/pgbench/pgbench.c,v 1.26 2003/08/04 00:43:11 momjian Exp $ + * $Header: /cvsroot/pgsql/contrib/pgbench/pgbench.c,v 1.27 2003/09/27 19:15:34 wieck Exp $ * * pgbench: a simple TPC-B like benchmark program for PostgreSQL * written by Tatsuo Ishii @@ -567,7 +567,7 @@ init(void) PQclear(res); } - snprintf(sql, 256, "%d\t%d\t%d\t\n", j, j / naccounts, 0); + snprintf(sql, 256, "%d\t%d\t%d\t\n", j, i / naccounts + 1, 0); if (PQputline(con, sql)) { fprintf(stderr, "PQputline failed\n");