Tom Lane wrote: > Ah. So the issue is that ANALYZE tries to do textin(byteaout(...)) > in order to produce a textual representation of the most common value > in the BYTEA column, and apparently textin feels that the string > generated by byteaout is not legal text. While Joe says that the > problem has gone away in CVS tip, I'm not sure I believe that.
I didn't either, except I tried it and it worked ;-) But you're undoubtedly correct that there are other cases which would break the current code. > A possible answer is to change the pg_statistics columns from text to > some other less picky datatype. (bytea maybe ;-)) Or should we > conclude that text is broken and needs to be fixed? Choice #3 would > be "bytea is broken and needs to be fixed", but I don't care for that > answer --- if bytea can produce an output string that will break > pg_statistics, then so can some other future datatype. BYTEA sounds like the best answer to me. TEXT is supposed to honor character set specific peculiarities, while bytea should be able to represent any arbitrary set of bytes. Joe ---------------------------(end of broadcast)--------------------------- TIP 4: Don't 'kill -9' the postmaster