Re: PGBench on Windows - connections are subprocesses?

2020-07-20 Thread Durumdara
Dear Tom! Tom Lane ezt írta (időpont: 2020. júl. 20., H, 15:38): > > There are -j threads in the pgbench process, and -c connections to > the server (hence -c backend processes on the server side). Each > of the pgbench threads is responsible for sending queries to a subset > of the connections

Re: PGBench on Windows - connections are subprocesses?

2020-07-20 Thread Tom Lane
Durumdara writes: > But the number of threads option (j I think) confused me. At first I > thought the total connection number is simply the multiplication of c and j > (subconnections). > As I saw this is untrue. > So I don't know how this utility works really in the background. There are -j th

Re: PGBench on Windows - connections are subprocesses?

2020-07-20 Thread Durumdara
I extend the question to understand why I was confused about this. In Delphi the connections are thread based. From a thread you can use more connections. But you can't use a connection from two or more threads concurrently! You can use subprocess farm, or subthread farm to make parallel performan

Re: pgbench and timestamps

2020-06-29 Thread Fabien COELHO
Hello Tom, The attached patch fixes some of the underlying problems reported by delaying the :var to $1 substitution to the last possible moments, so that what variables are actually defined is known. PREPARE-ing is also delayed to after these substitutions are done. It requires a mutex aro

Re: pgbench and timestamps

2020-06-25 Thread Jaime Soler
Thanks for your analysis. Regards El mié., 24 jun. 2020 a las 17:17, Tom Lane () escribió: > I wrote: > > David Rowley writes: > >> I don't often do much with pgbench and variables, but there are a few > >> things that surprise me here. > >> 1) That pgbench replaces variables within single quo

Re: pgbench and timestamps

2020-06-25 Thread Fabien COELHO
I'll look into it. Thanks for the analysis and CC-ing. -- Fabien.

Re: pgbench and timestamps

2020-06-24 Thread Tom Lane
I wrote: > David Rowley writes: >> I don't often do much with pgbench and variables, but there are a few >> things that surprise me here. >> 1) That pgbench replaces variables within single quotes, and; >> 2) that we still think it's a variable name when it starts with a digit, and; >> 3) We repla

Re: pgbench and timestamps

2020-06-24 Thread Tom Lane
David Rowley writes: > On Wed, 24 Jun 2020 at 20:41, Jaime Soler wrote: >> I don't know why pgbench use timestamp: «2006-03-01 00$1$2» instead of >> timestamp '2006-03-01 00:00:00' > I've not debugged it, but it looks like pgbench thinks that :00 is a > pgbench variable and is replacing each i

Re: pgbench and timestamps

2020-06-24 Thread Jaime Soler
Hi, Thanks for your comments, I worked around that problem because I was able to truncate the timestamp and use only the date part , alsoit might works the use of to_timestamp. But I would like to understand what is happening , I realized that pgbench is identified erroneously the minutes and se

Re: pgbench and timestamps

2020-06-24 Thread David Rowley
On Wed, 24 Jun 2020 at 20:41, Jaime Soler wrote: > > Hi, does anybody know what is wrong with pgbench in this case ?. Here is a > simple query to generate a random date in a interval time.sql: > > (select timestamp '2005-09-01' + random() * ( timestamp '2006-03-01 > 00:00:00' - timestamp '2005

Re: pgbench

2017-12-17 Thread Achilleas Mantzios
On 15/12/2017 23:18, John R Pierce wrote: On 12/15/2017 7:37 AM, Olga Lytvynova-Bogdanova wrote: Is there a way to integrate pgbench with TeamCity? If yes, could you share very briefly how to do this? I would suspect this is a question for TeamCity, not for postgresql.   I don't even know wha

Re: pgbench

2017-12-15 Thread John R Pierce
On 12/15/2017 7:37 AM, Olga Lytvynova-Bogdanova wrote: Is there a way to integrate pgbench with TeamCity? If yes, could you share very briefly how to do this? I would suspect this is a question for TeamCity, not for postgresql.   I don't even know what TeamCity actually is (google says 'Contin