"Matt Magoffin" <[EMAIL PROTECTED]> writes:
> Ugh, you're right of course! Somehow I had this wrong. So I tried to
> create an index on the xml[] result by casting to text[] but I got the
> "function must be immutable" error. Is there any reason the xml[] to
> text[] cast is not immutable?

Hmm ... I see that xmltotext() is marked 'stable' in pg_proc.h,
but texttoxml() is marked 'immutable', which is at best inconsistent.
It looks to me like they both depend on the GUC setting "xmloption",
which would mean they should both be stable.  Peter, is there a bug
there?  Also, is there a way to get rid of the GUC dependency so that
there's a reasonably safe way to index XML values?

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

Reply via email to