David Shadovitz wrote:
> I intended to call the CHAR-signature function like this:
> SELECT ABC('R');
>
> And the TEXT-signature function like this:
> SELECT ABC('Right');
>
> But I found that both calls invoke the TEXT-signature function. So is
> there any distinction between CHAR and TEXT? Can I somehow specify
> that the argument 'R' is to be treated as a CHAR, so the
> CHAR-signature version of ABC is executed?
If you want to force the CHAR version, do something like:
SELECT ABC('R'::char);
See:
http://www.postgresql.org/docs/view.php?version=7.3&idoc=0&file=sql-expressions.html#SQL-SYNTAX-TYPE-CASTS
HTH,
Joe