0

I do not know if this is the right place for this message to go, but there does not appear to be a forum specifically set up for the users of the PostgreSQL database, so this was the best match I could find.

Does anyone know what function or functions in Postgres would return the current date, and only that? I know of the 'now()' function, which returns the date and the timestamp, but that's no good for me; I need something which can separate the date and return only it. I'm currently building a program which requires a 'search by date' option, and the timestamp attached to the now command throws it off; no records appear in the returned set.

Anyone have any suggestions?

2
Contributors
1
Reply
2
Views
11 Years
Discussion Span
Last Post by pty
0

glad to see a postgresql user

i think what you're after is:

bc_dev=# select current_date;
    date    
------------
 2006-09-10
(1 row)
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.