You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Intelligently executes a graph query using snapshots if they exist, otherwise falls back to transient graphs.
202
+
Intelligently executes a graph query using snapshots if they exist,
203
+
otherwise falls back to transient graphs.
192
204
If no database is provided, uses the default database.
193
205
194
206
:param graph_name: Name of the graph to query.
195
-
:param query: The KQL query to execute after the graph() function. Must include proper project clause for graph-match queries.
207
+
:param query: The KQL query to execute after the graph() function.
208
+
Must include proper project clause for graph-match queries.
196
209
:param cluster_uri: The URI of the Kusto cluster.
197
210
:param database: Optional database name. If not provided, uses the default database.
198
211
:return: List of dictionaries containing query results.
199
-
212
+
200
213
Critical:
201
-
* Graph queries must have a graph-match clause and a projection clause. Optionally they may contain a where clause.
202
-
* Graph entities are only accessible in the graph-match context. When leaving the context (sub-sequent '|'), the data is treated as a table, and graph-specific functions (like labels()) will not be available.
203
-
* Always prefer expressing everything with graph patterns. Avoid using graph-to-table operator unless you have no other way around it.
204
-
* There is no id() function on graph entities. If you need a unique identifier, make sure to check the schema and use an appropriate property.
205
-
* There is no `type` property on graph entities. Use `labels()` function to get the list of labels for a node or edge.
206
-
* Properties that are used outside the graph-match context are renamed to `_` instead of `.`. For example, `node.name` becomes `node_name`.
207
-
* For variable length paths, you can use `all` or `any` to enforce conditions on all/any edges in variable path length elements (e.g. `()-[e*1..3]->() where all(e, labels() has 'Label')`).
214
+
* Graph queries must have a graph-match clause and a projection clause.
215
+
Optionally they may contain a where clause.
216
+
* Graph entities are only accessible in the graph-match scope.
217
+
When leaving that scope (sub-sequent '|'), the data is treated as a table,
218
+
and graph-specific functions (like labels()) will not be available.
219
+
* Always prefer expressing everything with graph patterns.
220
+
Avoid using graph-to-table operator unless you have no other way around it.
221
+
* There is no id() function on graph entities. If you need a unique identifier,
222
+
make sure to check the schema and use an appropriate property.
223
+
* There is no `type` property on graph entities.
224
+
Use `labels()` function to get the list of labels for a node or edge.
225
+
* Properties that are used outside the graph-match context are renamed to `_` instead of `.`.
226
+
For example, `node.name` becomes `node_name`.
227
+
* For variable length paths, you can use `all` or `any` to enforce conditions on all/any edges
228
+
in variable path length elements (e.g. `()-[e*1..3]->() where all(e, labels() has 'Label')`).
208
229
209
230
Examples:
210
-
231
+
211
232
# Basic node counting with graph-match (MUST include project clause):
0 commit comments