MCPcopy Index your code
hub / github.com/ent/ent / QueryNodes

Function QueryNodes

dialect/sql/sqlgraph/graph.go:937–941  ·  view source on GitHub ↗

QueryNodes queries the nodes in the graph query and scans them to the given values.

(ctx context.Context, drv dialect.Driver, spec *QuerySpec)

Source from the content-addressed store, hash-verified

935
936// QueryNodes queries the nodes in the graph query and scans them to the given values.
937func QueryNodes(ctx context.Context, drv dialect.Driver, spec *QuerySpec) error {
938 builder := sql.Dialect(drv.Dialect())
939 qr := &query{graph: graph{builder: builder}, QuerySpec: spec}
940 return qr.nodes(ctx, drv)
941}
942
943// CountNodes counts the nodes in the given graph query.
944func CountNodes(ctx context.Context, drv dialect.Driver, spec *QuerySpec) (int, error) {

Callers 15

sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92
sqlAllMethod · 0.92

Calls 3

nodesMethod · 0.95
DialectFunction · 0.92
DialectMethod · 0.65

Tested by 2

TestQueryNodesFunction · 0.68
TestQueryNodesSchemaFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…