Adding 1 week to a timestamp, which can be NULL or expired - Mailing list pgsql-general

From Alexander Farber
Subject Adding 1 week to a timestamp, which can be NULL or expired
Date
Msg-id CAADeyWgPPb4Z2kWSgG1xxKjsCk0znxpDjZsdY1OVDjPw+8LD-Q@mail.gmail.com
Whole thread Raw
Responses Re: Adding 1 week to a timestamp, which can be NULL or expired  (John R Pierce <pierce@hogranch.com>)
List pgsql-general
Hello,

I'm trying to add 1 week "VIP-status" to all users in a table:

   update pref_users set vip = max(vip, now()) + interval '1 week';

but max() doesn't work with timestamps.

Is there maybe still a way to solve it with a one-liner?

Thank you
Alex

pgsql-general by date:

Previous
From: Phoenix Kiula
Date:
Subject: Re: Installed. Now what?
Next
From: John R Pierce
Date:
Subject: Re: Adding 1 week to a timestamp, which can be NULL or expired