Greg Stark <gsst...@mit.edu> writes: > I wonder if we could get around this by inventing a new type > date_or_interval which looks at the input and decides which it is > using fairly strict rules. date_sub would take that type and do the > appropriate operation based on what the constant had in it.
Ick. This would be a pretty enormous blot on the type system to solve one special case, in a manner that would only be helpful to newbies who don't know that they ought to cast to eliminate the ambiguity. In fact it sounds quite a bit like the implicit-cast-to-text situations we just finished getting rid of ... regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers