Skip to content

Commit 3719152

Browse files
committed
done invokekustoquery
1 parent 9233a10 commit 3719152

File tree

3 files changed

+43
-28
lines changed

3 files changed

+43
-28
lines changed

docs/en-US/Invoke-KustoControlCommand.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ schema: 2.0.0
99

1010
## SYNOPSIS
1111

12-
Invokes a management command over an Azure Data Explorer Cluster.
12+
Invokes management commands over an Azure Data Explorer Cluster.
1313

1414
## SYNTAX
1515

@@ -109,7 +109,7 @@ Accept wildcard characters: False
109109

110110
### -OutputType
111111

112-
Determines the output type this cmdlet will produce. The default value is __`PSObject`__.
112+
Determines the output type this cmdlet will produce. __The default value is `PSObject`__.
113113

114114
```yaml
115115
Type: OutputType

docs/en-US/Invoke-KustoIngestFromStream.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ schema: 2.0.0
99

1010
## SYNOPSIS
1111

12-
Ingests stream into Azure Data Explorer.
12+
Ingests Streams into Azure Data Explorer.
1313

1414
## SYNTAX
1515

docs/en-US/Invoke-KustoQuery.md

Lines changed: 40 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ schema: 2.0.0
99

1010
## SYNOPSIS
1111

12-
{{ Fill in the Synopsis }}
12+
Invokes a KQL query over an Azure Data Explorer Cluster.
1313

1414
## SYNTAX
1515

@@ -24,23 +24,49 @@ Invoke-KustoQuery
2424

2525
## DESCRIPTION
2626

27-
{{ Fill in the Description }}
27+
The `Invoke-KustoQuery` cmdlet allows you to can be used to run
28+
[Kusto Query Language (KQL)](https://learn.microsoft.com/en-us/kusto/query/?view=microsoft-fabric) queries or
29+
[T-SQL](https://learn.microsoft.com/en-us/kusto/query/t-sql?view=microsoft-fabric) queries on the tables on a
30+
specified Database of your Azure Data Explorer Cluster.
2831

2932
## EXAMPLES
3033

31-
### Example 1
34+
### Example 1: Run a KQL Query
3235

3336
```powershell
34-
PS C:\> {{ Add example code here }}
37+
Invoke-KustoQuery 'search * | summarize count() by $table'
3538
```
3639

37-
{{ Add example description here }}
40+
This examples shows how to get the log count summarized by each table.
41+
42+
### Example 2: Run a KQL Query on specified Database
43+
44+
```powershell
45+
Invoke-KustoQuery 'myTable | take 10' -Database myDb
46+
```
47+
48+
### Example 3: Run a KQL Query with specified request properties
49+
50+
```powershell
51+
$requestProps = New-KustoClientRequestProperties -NoTruncation -ServerTimeout '00:05:00'
52+
Invoke-KustoQuery 'myTable | project fooProp, barProp' -RequestProperties $requestProps
53+
```
54+
55+
This example demonstrates how you can specify request properties for your query.
56+
See also [`New-KustoClientRequestProperties`](New-KustoClientRequestProperties.md) for more details.
57+
58+
- In this case `-NoTruncation` is particularly useful to overcome the 500k row limit on your query.
59+
- `-ServerTimeout '00:05:00'` allows the query to run for at least 5 minutes before timing out.
3860

3961
## PARAMETERS
4062

4163
### -Database
4264

43-
{{ Fill Database Description }}
65+
This non mandatory parameter determines which Database in your Cluster will be targetted by your ingest command.
66+
67+
> [!NOTE]
68+
>
69+
> If not supplied, the Database used will be the one specified when you called [`Connect-Kusto`](Connect-Kusto.md).
4470
4571
```yaml
4672
Type: String
@@ -56,7 +82,7 @@ Accept wildcard characters: False
5682
5783
### -OutputType
5884
59-
{{ Fill OutputType Description }}
85+
Determines the output type this cmdlet will produce. __The default value is `PSObject`__.
6086

6187
```yaml
6288
Type: OutputType
@@ -73,7 +99,7 @@ Accept wildcard characters: False
7399

74100
### -Query
75101

76-
{{ Fill Query Description }}
102+
The KQL or T-SQL query you want to run against a specified Database in your Cluster.
77103

78104
```yaml
79105
Type: String
@@ -87,25 +113,10 @@ Accept pipeline input: False
87113
Accept wildcard characters: False
88114
```
89115

90-
### -ProgressAction
91-
92-
{{ Fill ProgressAction Description }}
93-
94-
```yaml
95-
Type: ActionPreference
96-
Parameter Sets: (All)
97-
Aliases: proga
98-
99-
Required: False
100-
Position: Named
101-
Default value: None
102-
Accept pipeline input: False
103-
Accept wildcard characters: False
104-
```
105-
106116
### -RequestProperties
107117

108-
{{ Fill RequestProperties Description }}
118+
Request properties control how a query or command executes and returns results.
119+
For creating a `ClientRequestProperties` object, checkout [`New-KustoClientRequestProperties`](New-KustoClientRequestProperties.md).
109120

110121
```yaml
111122
Type: ClientRequestProperties
@@ -142,3 +153,7 @@ By default, this cmdlet outputs `PSObject`.
142153
## NOTES
143154

144155
## RELATED LINKS
156+
157+
[Kusto Query Language (KQL)](https://learn.microsoft.com/en-us/kusto/query/?view=microsoft-fabric)
158+
159+
[T-SQL](https://learn.microsoft.com/en-us/kusto/query/t-sql?view=microsoft-fabric)

0 commit comments

Comments
 (0)