"Bruno BAGUETTE" <pgsql-ml@baguette.net> writes:
> I'm looking for a way to convert a unix timestamp to a PostgreSQL date
> without using ::abstime which seems to be deprecated.
abstime is not yet deprecated in my mind, precisely because it's still
the easiest way to do the reverse of "extract(epoch from timestamp)".
The cleanest alternative I know of is
select 'epoch'::timestamptz + (unixtimestamphere) * '1 sec'::interval;
but this still leaves an unsatisfied feeling. Sooner or later we'll
probably invent an explicit function to do this conversion.
regards, tom lane