Search Postgresql Archives

Re: Odd array issue

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

 



Craig Ringer <craig@xxxxxxxxxxxxxxxxxxxxx> writes:
> The following query should return 2 records, but returns zero instead:

> test=> select x, regexp_matches(x::text, 'm')
> test-> FROM generate_series(1,2) AS x;
>  x | regexp_matches
> ---+----------------
> (0 rows)

No, that's correct.  The SRF returns an empty set, so there are no
output records.  The behavior you seem to be imagining would make it
impossible to distinguish empty set from a single row containing NULL.

			regards, tom lane

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[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