]> granicus.if.org Git - postgresql/commit
pgbench: Add a real expression syntax to \set
authorRobert Haas <rhaas@postgresql.org>
Mon, 2 Mar 2015 19:21:41 +0000 (14:21 -0500)
committerRobert Haas <rhaas@postgresql.org>
Mon, 2 Mar 2015 19:21:41 +0000 (14:21 -0500)
commit878fdcb843e087cc1cdeadc987d6ef55202ddd04
tree46cea8fefefd5d302aef823683372f7cf6b0fd80
parentebd092bc2a07787b31b249d62033b9c8140a5d85
pgbench: Add a real expression syntax to \set

Previously, you could do \set variable operand1 operator operand2, but
nothing more complicated.  Now, you can \set variable expression, which
makes it much simpler to do multi-step calculations here.  This also
adds support for the modulo operator (%), with the same semantics as in
C.

Robert Haas and Fabien Coelho, reviewed by Álvaro Herrera and
Stephen Frost
contrib/pgbench/.gitignore
contrib/pgbench/Makefile
contrib/pgbench/exprparse.y [new file with mode: 0644]
contrib/pgbench/exprscan.l [new file with mode: 0644]
contrib/pgbench/pgbench.c
contrib/pgbench/pgbench.h [new file with mode: 0644]
doc/src/sgml/pgbench.sgml
src/tools/msvc/Mkvcbuild.pm