Date manipulation

From: Mark <mark(at)zserve(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Date manipulation
Date: 2001-05-31 16:22:48
Message-ID: 200105311714.f4VHEbW24511@mail.ldssingles.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


How does one perform date manipulation within SQL? For example, SQL
Server has a dateadd() function that takes a date part, scalar, and the
date to manipulate.

I have a query that determines the number of days that are between now
and a particular date that looks something like this:

select datediff (dd, now (), column) as difference_in_days from ...

Anything available short of coding my own function?

Thanks,

Mark

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2001-05-31 16:42:28 Re: 7.1.1 Lock Problems on Views
Previous Message Josh Berkus 2001-05-31 16:03:59 Re: rowset Return from postgresql