Re: SPI_ERROR_CONNECT

From: Willem Buitendyk <willem(at)pcfish(dot)ca>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: SPI_ERROR_CONNECT
Date: 2008-02-12 00:32:25
Message-ID: 47B0E919.8030209@pcfish.ca
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

The problem was with the following:

FOR current_row IN SELECT * from temp_tags_18_counted

The select from the [temp_tags_18_counted] view is made up of 3 cross
joins. When I simplify and remove the joins everything works. I tried
this with some test data with only a few rows and the joins in place and
it works too.
In the production data table there are about 250K rows. Is it possible
that calls to queries are colliding here or not giving each other enough
time before being whisked around to next call in the FOR loop?

cheers,

willem

Tom Lane wrote:
> Willem Buitendyk <willem(at)pcfish(dot)ca> writes:
>
>> ERROR: SPI_connect failed: SPI_ERROR_CONNECT
>> CONTEXT: PL/pgSQL function "pop_tag_day_over" line 17 at FOR over
>> SELECT rows
>>
>
> Hm, what PG version is this? And could we have a complete test case
> not just the function? (I don't feel like trying to reverse-engineer
> your tables and views...)
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: explain analyze is your friend
>
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2008-02-12 00:36:05 Re: SPI_ERROR_CONNECT
Previous Message Erik Jones 2008-02-12 00:25:41 Re: postgresql book - practical or something newer?