Get Year, Month in PostgreSQL
Thursday, March 19th, 2009This example will show you how to get year, month using date_part from table in PostgreSQL database.
The date_part function is the traditional Postgres equivalent to the SQL-function extract:
date_part(’field’, source)
Note that here the field value needs to be a string. [...]