MCPcopy
hub / github.com/django/django / coalesce

Method coalesce

django/db/models/functions/text.py:112–122  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

110 )
111
112 def coalesce(self):
113 # null on either side results in null for expression, wrap with
114 # coalesce
115 c = self.copy()
116 c.set_source_expressions(
117 [
118 Coalesce(expression, Value(""))
119 for expression in c.get_source_expressions()
120 ]
121 )
122 return c
123
124
125class Concat(Func):

Callers 2

pipes_concat_sqlMethod · 0.95

Calls 5

CoalesceClass · 0.90
ValueClass · 0.90
copyMethod · 0.45

Tested by 1