Re: Running concurrent txns and measuring the timings in Postgres

2019-07-26 Thread Adrian Ho
On 25/7/19 5:24 AM, Souvik Bhattacherjee wrote: > I got this thing running and hopefully works as expected. The txns are > stored in insert_txn1.sql, insert_txn2.sql, ... > Please let me know if you find any issues with this. > Script is attached. > Even if you're using the ancient Bash version 3 (

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Adrian Klaver
On 7/24/19 2:24 PM, Souvik Bhattacherjee wrote: I got this thing running and hopefully works as expected. The txns are stored in insert_txn1.sql, insert_txn2.sql, ... Please let me know if you find any issues with this. Script is attached. I'm hardly a BASH guru so someone else will need to c

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Souvik Bhattacherjee
I got this thing running and hopefully works as expected. The txns are stored in insert_txn1.sql, insert_txn2.sql, ... Please let me know if you find any issues with this. Script is attached. On Wed, Jul 24, 2019 at 5:11 PM Adrian Klaver wrote: > On 7/24/19 1:52 PM, Souvik Bhattacherjee wrote:

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Adrian Klaver
On 7/24/19 1:52 PM, Souvik Bhattacherjee wrote: >Well it depends on the part you have not filled in, what client(s) you > are using and how the transactions are being generated? Using a psql client and txns are generated manually at this point. Each txn is stored separately in a .sql file and

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Souvik Bhattacherjee
>Well it depends on the part you have not filled in, what client(s) you > are using and how the transactions are being generated? Using a psql client and txns are generated manually at this point. Each txn is stored separately in a .sql file and are fired from different psql sessions, if that help

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Adrian Klaver
On 7/24/19 1:42 PM, Souvik Bhattacherjee wrote: > The duplicate elimination is being handled by ON CONFLICT or some custom > process in the code generating the transactions? Yes, we used ON CONFLICT for that. Thanks btw. > If the transactions are being created from a single app/script could

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Souvik Bhattacherjee
> The duplicate elimination is being handled by ON CONFLICT or some custom > process in the code generating the transactions? Yes, we used ON CONFLICT for that. Thanks btw. > If the transactions are being created from a single app/script could you > not just use 'timing' to mark the beginning of

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Adrian Klaver
On 7/24/19 12:22 PM, Souvik Bhattacherjee wrote: > It would help to know what problem you are trying to solve? Multiple txns are inserting tuples into a table concurrently. Wanted to measure the total time taken to complete the insertion process. Some txns overlap with others on the tuples t

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Rob Sargent
> On Jul 24, 2019, at 1:22 PM, Souvik Bhattacherjee wrote: > > > It would help to know what problem you are trying to solve? > > Multiple txns are inserting tuples into a table concurrently. Wanted to > measure > the total time taken to complete the insertion process. Some txns overlap > wit

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Souvik Bhattacherjee
> It would help to know what problem you are trying to solve? Multiple txns are inserting tuples into a table concurrently. Wanted to measure the total time taken to complete the insertion process. Some txns overlap with others on the tuples they insert. Duplicate tuples are not inserted. On Wed,

Re: Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Adrian Klaver
On 7/24/19 9:54 AM, Souvik Bhattacherjee wrote: Hi, Is there a standard procedure to execute two or more concurrent txns at the same time? I understand that if we want to run concurrent txns, we need to execute them from different psql sessions. But how do we make sure that they begin executi

Running concurrent txns and measuring the timings in Postgres

2019-07-24 Thread Souvik Bhattacherjee
Hi, Is there a standard procedure to execute two or more concurrent txns at the same time? I understand that if we want to run concurrent txns, we need to execute them from different psql sessions. But how do we make sure that they begin execution almost at the same time. Also, I'm interested in