On Feb 22, 2006, at 1:51 , Karsten Hilbert wrote:
I specifically wanted to avoid that by something like 'infinite'::interval in some way or other such that I could always do "... where now < date_of_birth + max_age ..." and not need an "... or max_age is null ..." in all the places.
I'd wrap it in an SQL function (untested): create function ok_to_vaccinate(date, interval) returns boolean language sql as' select current_timestamp < $1 + $2 or $2 is null '; Michael Glaesemann grzm myrealbox com