array surprising behavior

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема array surprising behavior
Дата
Msg-id 20040204120838.GA10446@dcc.uchile.cl
обсуждение исходный текст
Ответы Re: array surprising behavior  (Joe Conway <mail@joeconway.com>)
Список pgsql-hackers
Hi,

I think this is most surprising behavior -- shouldn't the UPDATE raise
an error?

alvherre=# create table foo (a int[]);
CREATE TABLE
alvherre=# insert into foo values (null);
INSERT 33649 1
alvherre=# update foo set a[3] = '42';
UPDATE 1
alvherre=# select a, a is null from foo;a | ?column?
---+----------  | t
(1 fila)
alvherre=# select version();                                                 version
-----------------------------------------------------------------------------------------------------------PostgreSQL
7.5develon i686-pc-linux-gnu, compiled by GCC gcc (GCC) 3.3.1 (Mandrake Linux 9.2 3.3.1-2mdk)
 
(1 fila)


(This is CVS tip as of a couple weeks ago)

-- 
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"El destino baraja y nosotros jugamos" (A. Schopenhauer)


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

Предыдущее
От: Andrew Rawnsley
Дата:
Сообщение: Re: Recursive queries?
Следующее
От: Christopher Browne
Дата:
Сообщение: Re: Recursive queries?