Re: [HACKERS] type coerce problem with lztext
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jan Wieck <wieck@debis.com>
Cc: PostgreSQL HACKERS <pgsql-hackers@postgreSQL.org>
Date: 2000-02-27T18:58:31Z
Lists: pgsql-hackers
wieck@debis.com (Jan Wieck) writes: > There are functions text(lztext) and lztext(text) too, but > the system is unable to find an operator if one compares > text=lztext in a query. IIRC, creating a function named as > the target type and taking the source type is what made auto- > type-conversion work - so what am I missing here? Yup, TypeCategory was the missing ingredient. Seems to work now. > Yes, the 3043 bytes long rule action string got stored in 855 > bytes in pg_rewrite. That's 71.9% compression rate on this > attempt! Over all the rules in the regression test database, I see: regression=# select sum(length(ev_action)),sum(octet_length(ev_action)) from pg _rewrite; sum | sum --------+------- 105270 | 38091 (1 row) or about 64% compression. Not bad... regards, tom lane