[Fixed]-Postgres function json_array_elements does not found while django's tests


Mistake in query json_array_elements(animated_groups)

Needs change to this:


Postgres JSON processing functions such as json_array_elements(animated_groups::json), jsonb_array_elements(animated_groups::jsonb) will take json or jsonb values.

Because postgres JSON field(animated_groups) are store as text format or binary format.
so we need to convert the type by using either ::json or ::jsonb it give the json or jsonb format

check here

Leave a comment