﻿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
30336	F() expression wrong result on postgres JSONField	blue-note	armansabyr	"On the model

{{{
class Product(Model):
    properties = JSONField()
}}}

when querying with {{{Product.objects.values('properties__color')}}}, the resulting query is {{{SELECT (""product"".""properties"" -> 'color') FROM ""product""}}}

However, when using the equivalent F() expression {{{product = Product.objects.values(color=F('properties__color'))}} the resulting query is {{{SELECT ""product"".""properties"" AS ""color"" FROM ""product""}}}, which ignores part of the field name
"	New feature	closed	contrib.postgres	dev	Normal	duplicate	jsonfield, postgres, F		Unreviewed	0	0	0	0	0	0
