temp tables failes in transaction mode

Поиск
Список
Период
Сортировка
От Petter Reinholdtsen
Тема temp tables failes in transaction mode
Дата
Msg-id 199909010907.LAA06846@minerva.cc.uit.no
обсуждение исходный текст
Ответы Re: [BUGS] temp tables failes in transaction mode  (Bruce Momjian <maillist@candle.pha.pa.us>)
Список pgsql-bugs
Your name               : Petter Reinholdtsen
Your email address      : pere@td.org.uit.no

System Configuration
---------------------
  Architecture (example: Intel Pentium)         : Intel Pentium
  Operating System (example: Linux 2.0.26 ELF)  : RedHat Linux 5.2
  PostgreSQL version (example: PostgreSQL-6.5)  :   PostgreSQL-6.5
  Compiler used (example:  gcc 2.8.0)           : GCC 2.7.2.3

Please enter a FULL description of your problem:
------------------------------------------------

It seems that using a temp table in transaction mode makes the backend
crash.  On the other end I get the following message:

  pqReadData() -- backend closed the channel unexpectedly.
        This probably means the backend terminated abnormally
        before or while processing the request.
  We have lost the connection to the backend, so further processing is
  impossible.

I discovered the problem using update on a temp table, but have
discovered later that select also triggers this bug.

There is no messages in syslog when this happends.

Please describe a way to repeat the problem.   Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------

Enter the following in psql:

  BEGIN WORK;

  SELECT 'Testing temp tables'::text AS n1, ''::text AS n2
    INTO TEMP TABLE testing;

  SELECT * FROM testing;

  UPDATE testing
    SET n1 = SUBSTR(n1, 0, POSITION(' ' in n1)),
        n2 = SUBSTR(n1, POSITION(' ' in n1)+1);

  SELECT * FROM testing;

  COMMIT WORK;

It will crash on the first select, and on the update if the first
select is removed.

If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------

My workaround will probably to make a permanent table to insert my
values in.  Another workaround is to remove 'begin work' and not work
in transaction mode.

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Christian Denning
Дата:
Сообщение: Re: Linux/Postgres 6.5 problems using jdbc w/jdk1.2
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [BUGS] temp tables failes in transaction mode