Re: problem trying to create a temp table

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: problem trying to create a temp table
Дата
Msg-id 4F4794CC.80407@archonet.com
обсуждение исходный текст
Ответ на Re: problem trying to create a temp table  (<mgould@isstrucksoftware.net>)
Список pgsql-general
On 24/02/12 13:36, mgould@isstrucksoftware.net wrote:
> How do I access it. I just did that and when I try and access it with a
> ERROR: relation "sessionsetting" does not exist
> LINE 1: select * from "sessionsetting"

=> CREATE SCHEMA foo;
CREATE SCHEMA
=> CREATE TABLE foo.table1 (id int);
CREATE TABLE
=> SET search_path = foo;
SET
=> INSERT INTO table1 VALUES (1),(2),(3);
INSERT 0 3
=> CREATE TEMP TABLE table1 (id int);
CREATE TABLE
=> INSERT INTO table1 VALUES (4),(5),(6);
INSERT 0 3
=> SELECT * FROM table1;
  id
----
   4
   5
   6
(3 rows)
=> DROP TABLE table1;
DROP TABLE
=> SELECT * FROM table1;
  id
----
   1
   2
   3
(3 rows)

Try "SELECT * FROM pg_namespace" to see the various temp schemas being
created.

--
   Richard Huxton
   Archonet Ltd

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

Предыдущее
От:
Дата:
Сообщение: Re: problem trying to create a temp table
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: problem trying to create a temp table