MCPcopy
hub / github.com/django/django / as_sql

Method as_sql

django/db/models/functions/json.py:78–83  ·  view source on GitHub ↗
(self, compiler, connection, **extra_context)

Source from the content-addressed store, hash-verified

76 super().__init__(*expressions)
77
78 def as_sql(self, compiler, connection, **extra_context):
79 if not connection.features.has_json_object_function:
80 raise NotSupportedError(
81 "JSONObject() is not supported on this database backend."
82 )
83 return super().as_sql(compiler, connection, **extra_context)
84
85 def join(self, args):
86 pairs = zip(args[::2], args[1::2], strict=True)

Callers 1

as_nativeMethod · 0.95

Calls 2

NotSupportedErrorClass · 0.90
as_sqlMethod · 0.45

Tested by

no test coverage detected