Tom Lane wrote:
> We could possibly fix this by fooling with the precedence of the
> productions for postfix '%', but I'm worried that that would have
> unintended side-effects. What I'd like to propose instead is that
> we remove prefix and postfix '%' entirely --- and also '^', which
> is the only other hard-wired operator that appears in all three
> forms in the grammar. There are no actual uses of prefix or postfix
> '^' in pg_operator, so that loses us nothing. Prefix and postfix '%'
> exist, but only for the float8 datatype, not anything else; and I
> can't imagine a good reason to write those rather than trunc() or
> round(). (Quick: which is which, and how would you remember?)
Agreed. I didn't know we even supported unary % and ~, and I doubt
anyone else did either. We just need to mark it as a non-backward
compatible change in CVS commit so I mention it in the release notes.
-- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610)
359-1001+ If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square,
Pennsylvania19073