Search Postgresql Archives

Re: Can not match 0 on bytea

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

 



	 seiliki@xxxxxxxxxxxxx wrote:

> Data type of table1.c1 is bytea. That column stores binary data. The
> following matchings do not work. What is the right syntax?
> 
> TIA
> CN
> ---------------
> select c1 ~ E'\000' from table1;
> select c1 LIKE E'%\000%' from table1;

selection position(E'\\000'::bytea in c1) from table1;
The value is 0 when there is no match and >0 otherwise.

Best regards,
-- 
Daniel
PostgreSQL-powered mail user agent and storage: http://www.manitou-mail.org

-- 
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