﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
25556	Add DatePart db expression to allow complex lookups on date parts (e.g. year, month, day)	David Filipovic	David Filipovic	"Currently it is not possible to filter by matching the year/month/day part of two separate date fields.

I propose something to the effect of:


{{{
from django.db.models.expressions import DatePart

MyModel.objects.filter(date1__month=DatePart('date2', 'month'))
}}}
"	New feature	closed	Database layer (models, ORM)	dev	Normal	duplicate	db expressions	josh.smeaton@…	Accepted	1	1	1	1	0	0
