Search Postgresql Archives

Re: stable function called for every row?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I isolated my problem a little bit:

CREATE FUNCTION get_array() RETURNS integer[] AS
$BODY$
BEGIN
  RAISE INFO 'get_array';
  RETURN ARRAY[1, 2];
END
$BODY$ LANGUAGE 'plpgsql' STABLE;

And now

SELECT * FROM generate_series(1,3) a(b) where array[b] <@ core.get_array();

gives me:

INFO:  get_array
INFO:  get_array
INFO:  get_array
 b 
---
 1
 2
(2 rows)

Why?? Wlli functions which returns an array not be cached?

Regards,
  Gerhard

Attachment: signature.asc
Description: Digital signature


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux