"Esh, Andrew" <[EMAIL PROTECTED]> writes: > I upgraded from 7.1beta5 to 7.4.1 recently, and I noticed that many of > my character varying arrays were getting a trailing space inserted > into their last value. This appears to be the result of white space > being misplaced during the INSERT/UPDATE command. If there is a space > before the close-curly-brace, it gets appended to the last quoted > value.
It's been that way since 7.2, and was intentional. IIRC, the array parser's behavior in 7.1 and before was inconsistent across datatypes, and we concluded this was the closest we could get to backwards compatibility while still having something moderately sane. It is documented: You may write whitespace before a left brace, after a right brace, or before any individual item string. Whitespace after an item is not ignored, however: after skipping leading whitespace, everything up to the next right brace or delimiter is taken as the item value. See http://www.postgresql.org/docs/7.4/static/arrays.html#AEN5228 regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 6: Have you searched our list archives? http://archives.postgresql.org