MCPcopy
hub / github.com/django/django / has_results

Method has_results

django/db/models/sql/compiler.py:1587–1592  ·  view source on GitHub ↗

Backends (e.g. NoSQL) can override this in order to use optimized versions of "query has any results."

(self)

Source from the content-addressed store, hash-verified

1585 return rows
1586
1587 def has_results(self):
1588 """
1589 Backends (e.g. NoSQL) can override this in order to use optimized
1590 versions of "query has any results."
1591 """
1592 return bool(self.execute_sql(SINGLE))
1593
1594 def execute_sql(
1595 self, result_type=MULTI, chunked_fetch=False, chunk_size=GET_ITERATOR_CHUNK_SIZE

Callers

nothing calls this directly

Calls 1

execute_sqlMethod · 0.95

Tested by

no test coverage detected