pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@gmail.com>
To: Simeó Reig <simeo.reig@grupoincofisa.com>
Cc: pgsql-general@postgresql.org
Subject: Re: pgbench
Date: Thu, 03 Oct 2013 07:16:52 -0700
Message-ID: <524D7C54.8070701@gmail.com> (raw)
In-Reply-To: <57c75d91fcc3d9ccc3a928548b6d24a9@mailserver.grupoincofisa.com>
References: <c7576ae69ced88ce09cb8c004145a460@mailserver.grupoincofisa.com>
	<524D7668.4050301@gmail.com>
	<57c75d91fcc3d9ccc3a928548b6d24a9@mailserver.grupoincofisa.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-general>

On 10/03/2013 07:11 AM, Simeó Reig wrote:
> A 2013-10-03 15:51, Adrian Klaver escrigué:
>> On 10/03/2013 06:21 AM, Simeó Reig wrote:
>>>   Hello
>>>
>>>   I was doing a performance test with pgbench with a pretty long queries
>>> and I have the next error:
>>>
>>>   $ pgbench -n -c1 -T 3 -f veins_pgbench.sql pdn
>>>   Client 0 aborted in state 0: ERROR:  syntax error at end of input
>>>   LINE 1: ...(abc.persones.provincia = abc.poblacions.cod_provinc
>>>   ^
>>>   transaction type: Custom query
>>>   scaling factor: 1
>>>   query mode: simple
>>>   number of clients: 1
>>>   number of threads: 1
>>>   duration: 3 s
>>>   number of transactions actually processed: 0
>>>   tps = 0.000000 (including connections establishing)
>>>   tps = 0.000000 (excluding connections establishing)
>>>
>>>   I believe pgbench has a very low limit with the queries you can put
>>> inside a file with the 't' option.
>>>   Am I right? How can avoid it ?
>>
>>
>> Well first you say 't' option but show 'T' option, they are different.
>>
>> Second the error is reporting a syntax error in your script, so I
>> would look there first.
>
> Yes, I did I mistake. I would say 'f' option (file option) not 't'
> option, sorry . But no, there is no mistake with the script, I can do:
>
> # psql -d pdn < veins_pgbench.sql
>
> and it works perfectly
>
> thanks Adrian, I'm almost sure that the problem is the query is too long
> for pgbench (1600 characters)

You have not shown the query, but could you be running into the belwo:

http://www.postgresql.org/docs/9.3/interactive/pgbench.html

"The format of a script file is one SQL command per line; multiline SQL 
commands are not supported. Empty lines and lines beginning with -- are 
ignored. Script file lines can also be "meta commands", which are 
interpreted by pgbench itself, as described below."

>
> Best regards
>
> Simeó Reig
> Barcelona (Spain)
>
>
>
>


-- 
Adrian Klaver
adrian.klaver@gmail.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



view thread (22+ messages)  latest in thread

Message-ID: <524D7C54.8070701@gmail.com>
Permalink:  ../524D7C54.8070701@gmail.com/
Also on:    postgresql.org/message-id/524D7C54.8070701@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: adrian.klaver@gmail.com, simeo.reig@grupoincofisa.com
  Subject: Re: pgbench
  In-Reply-To: <524D7C54.8070701@gmail.com>
  References: <c7576ae69ced88ce09cb8c004145a460@mailserver.grupoincofisa.com> <524D7668.4050301@gmail.com> <57c75d91fcc3d9ccc3a928548b6d24a9@mailserver.grupoincofisa.com> <524D7C54.8070701@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox