Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit b7a67c2

Browse files
committed
Add a comment explaining one of the ways that pgbench fails to fully
comply with TPC-B. Per Itagaki Takahiro and discussion of bug#3681.
1 parent 3030f18 commit b7a67c2

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

contrib/pgbench/pgbench.c

+11-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* $PostgreSQL: pgsql/contrib/pgbench/pgbench.c,v 1.76 2008/03/10 01:23:04 tgl Exp $
2+
* $PostgreSQL: pgsql/contrib/pgbench/pgbench.c,v 1.77 2008/03/12 02:18:33 tgl Exp $
33
*
44
* pgbench: a simple benchmark program for PostgreSQL
55
* written by Tatsuo Ishii
@@ -811,6 +811,16 @@ init(void)
811811
{
812812
PGconn *con;
813813
PGresult *res;
814+
/*
815+
* Note: TPC-B requires at least 100 bytes per row, and the "filler"
816+
* fields in these table declarations were intended to comply with that.
817+
* But because they default to NULLs, they don't actually take any
818+
* space. We could fix that by giving them non-null default values.
819+
* However, that would completely break comparability of pgbench
820+
* results with prior versions. Since pgbench has never pretended
821+
* to be fully TPC-B compliant anyway, we stick with the historical
822+
* behavior.
823+
*/
814824
static char *DDLs[] = {
815825
"drop table if exists branches",
816826
"create table branches(bid int not null,bbalance int,filler char(88)) with (fillfactor=%d)",

0 commit comments

Comments
 (0)