public inbox for [email protected]  
help / color / mirror / Atom feed
From: hector vass <[email protected]>
To: Shaozhong SHI <[email protected]>
Cc: Bruce Momjian <[email protected]>
Cc: pgsql-sql <[email protected]>
Subject: Re: Concurrently run scipts
Date: Thu, 26 Oct 2023 10:21:26 +0100
Message-ID: <CAJJx+iVextjyh4XFaTVA5qdMnrpHJ=8EN0q58N=cSOeHkUHHvQ@mail.gmail.com> (raw)
In-Reply-To: <CA+i5Jwb7JYeY=33w-+y4UP1vvhZkJS1Lyqur3Uf3okAyMuaErQ@mail.gmail.com>
References: <CA+i5JwbNtevizuSK5L_pBotXSDary=mxjjO=SpFn3ktciGbOBg@mail.gmail.com>
	<[email protected]>
	<CAJJx+iVhpkKtm=MGNOMSedEsOOHpqeZ+=Vvjj_5n5-sCdH5U6Q@mail.gmail.com>
	<CA+i5Jwb7JYeY=33w-+y4UP1vvhZkJS1Lyqur3Uf3okAyMuaErQ@mail.gmail.com>

max_connections

..which is set in postgresql.conf
select * from pg_settings() where setting~'conn'




On Thu, 26 Oct 2023, 09:01 Shaozhong SHI, <[email protected]> wrote:

> How many scripts can be run concurrently but independently?
>
> Regards,
>
> David
>
> On Wed, 25 Oct 2023 at 21:43, hector vass <[email protected]> wrote:
>
>> Concurrently but independently
>> psql -f script1 & psql -f script2 && fg
>> Similar in windows can be achieved using start iirc
>>
>> On Wed, 25 Oct 2023, 21:15 Bruce Momjian, <[email protected]> wrote:
>>
>>> On Wed, Oct 25, 2023 at 08:57:03PM +0100, Shaozhong SHI wrote:
>>> > In psql  we run scripts sequentially like the following:
>>> >
>>> > \ir script1
>>> > \ir script2
>>> >
>>> >
>>> > Is there something similar for concurrent running script?
>>>
>>> Uh, yeah, see the use of \! and & starting on slide 59:
>>>
>>>         https://momjian.us/main/writings/pgsql/locking.pdf
>>>
>>> --
>>>   Bruce Momjian  <[email protected]>        https://momjian.us
>>>   EDB                                      https://enterprisedb.com
>>>
>>>   Only you can decide what is important to you.
>>>
>>>
>>>


view thread (7+ messages)  latest in thread

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 using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Concurrently run scipts
  In-Reply-To: <CAJJx+iVextjyh4XFaTVA5qdMnrpHJ=8EN0q58N=cSOeHkUHHvQ@mail.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 agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox