Frank_Lupo Frank_Lupo <frank_lupo@telemail.it> writes:
> select 'aaa'+'aaa';
> return :
> ?column?
> ----------
> ?
"+" is not the operator for concatenation. Use the SQL-standard
concatenation operator, "||".
Just FYI, what you seem to be getting is coercion to type "char"
(the single-byte char, not char(N)) and then addition of character
values.
If you really insist on spelling concatenation as "+", try
create operator + (leftarg=text, rightarg=text, procedure=textcat);
This will work better than making one for varchar because text is
the preferred string type.
regards, tom lane