Thread: Wich program generates "list index out of range" ? pgadmin or the server ?
Hi,
My db have some complex triggers and it failed when inserting line.
I use Pgadmin and it display message "list index out of range".
Could someone tell me which program is responsible of this message, pgadmin or the remote server ?
Thanks
My db have some complex triggers and it failed when inserting line.
I use Pgadmin and it display message "list index out of range".
Could someone tell me which program is responsible of this message, pgadmin or the remote server ?
Thanks
Re: Wich program generates "list index out of range" ? pgadmin or the server ?
From
Steve Midgley
Date:
On Tue, Dec 19, 2023 at 12:23 AM intmail01 <intmail01@gmail.com> wrote:
Hi,
My db have some complex triggers and it failed when inserting line.
I use Pgadmin and it display message "list index out of range".
Could someone tell me which program is responsible of this message, pgadmin or the remote server ?
I'm not sure where it's coming from but it likely means that your query is not returning any results, or a subquery is not returning results. Pgadmin itself won't care if your resultset is zero rows, but something internal to your query could be causing this. I'm guessing your complex triggers or related insert statement is dependent on a value which is not being returned as needed. But others here with deeper expertise may have better input for you. For me, I'd recommend trying to examine the different pieces of the trigger function and the insert function separately to try to locate the source more precisely..
Steve
Re: Wich program generates "list index out of range" ? pgadmin or the server ?
From
hubert depesz lubaczewski
Date:
On Tue, Dec 19, 2023 at 11:26:46AM +0300, intmail01 wrote: > My db have some complex triggers and it failed when inserting line. > I use Pgadmin and it display message "list index out of range". > Could someone tell me which program is responsible of this message, pgadmin > or the remote server ? Connect with psql, and generate the same problem (same inserts). And you will know if the server is returning it. For what it's worth, in pg sources there is just one please where the phrase "list index out of range" exists, and it's in tests of plpython code. So, perhaps you have some trigger in plpython? Best regards, depesz
Hi,
I try an insert clause with psql command and there is no error.
I use also libreoffice base interface and it works.
The Pgadmin command line works fine too.
The only failed interface is the Pgadmin array. It shows "list index out of range" for insertion in the array.
Best regards.
On Wed, Dec 20, 2023 at 1:26 PM hubert depesz lubaczewski <depesz@depesz.com> wrote:
On Tue, Dec 19, 2023 at 11:26:46AM +0300, intmail01 wrote:
> My db have some complex triggers and it failed when inserting line.
> I use Pgadmin and it display message "list index out of range".
> Could someone tell me which program is responsible of this message, pgadmin
> or the remote server ?
Connect with psql, and generate the same problem (same inserts).
And you will know if the server is returning it.
For what it's worth, in pg sources there is just one please where the
phrase "list index out of range" exists, and it's in tests of plpython
code. So, perhaps you have some trigger in plpython?
Best regards,
depesz
Re: Wich program generates "list index out of range" ? pgadmin or the server ?
From
hubert depesz lubaczewski
Date:
On Thu, Dec 21, 2023 at 02:46:53PM +0300, intmail01 wrote: > Hi, > > I try an insert clause with psql command and there is no error. > I use also libreoffice base interface and it works. > The Pgadmin command line works fine too. > The only failed interface is the Pgadmin array. It shows "list index out > of range" for insertion in the array. That kinda answers the question about "which program generates...", doesn't it? Best regards, depesz