Search Postgresql Archives

Re: md5 of table

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

 



On 09/01/2011 12:26 PM, Pavel Stehule wrote:
Hello

postgres=# create table tt(a int, b varchar);
CREATE TABLE
postgres=# insert into tt values(10,'hello');
INSERT 0 1

postgres=# select md5(array_to_string(array_agg(md5(tt::text)),'')) from tt;
                md5
----------------------------------
  20a92a676f52699e613da1bb114bd6f0
(1 row)

Regards

Pavel Stehule
Would be perfect, but 8.2 can't cast a UDT to text.
ERROR:  cannot cast type tt to text
LINE 1: select tt::text from tt

Thanks
Sim

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