Re: pgbench - allow backslash-continuations in custom scripts

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andres Freund <andres(at)anarazel(dot)de>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, Josh Berkus <josh(at)agliodbs(dot)com>, PostgreSQL Developers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pgbench - allow backslash-continuations in custom scripts
Date: 2015-07-03 16:40:45
Message-ID: alpine.DEB.2.10.1507031831560.29652@sto
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


> (although actually, why wouldn't we want to just implement variable
> substitution exactly like it is in psql?

Pgbench variable substitution is performed when the script is run, not
while the file is being processed for being split, which is when a lexer
would be used. The situation is not the same with psql. The most it could
do would be to keep track of what substitution are done in queries.

> So this is looking *eminently* doable.

Possibly. How much more effort would be involved compared to the quick
patch I did, I wonder:-)

--
Fabien.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2015-07-03 16:49:31 Re: WAL logging problem in 9.4.3?
Previous Message Fujii Masao 2015-07-03 16:39:42 Re: WAL logging problem in 9.4.3?