Saved Search
    Value object for saved search results. Azure REST API version: 2020-08-01. Prior API version in Azure Native 1.x: 2020-08-01. Other available API versions: 2015-03-20.
Example Usage
SavedSearchCreateOrUpdate
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
    var savedSearch = new AzureNative.OperationalInsights.SavedSearch("savedSearch", new()
    {
        Category = "Saved Search Test Category",
        DisplayName = "Create or Update Saved Search Test",
        FunctionAlias = "heartbeat_func",
        FunctionParameters = "a:int=1",
        Query = "Heartbeat | summarize Count() by Computer | take a",
        ResourceGroupName = "TestRG",
        SavedSearchId = "00000000-0000-0000-0000-00000000000",
        Tags = new[]
        {
            new AzureNative.OperationalInsights.Inputs.TagArgs
            {
                Name = "Group",
                Value = "Computer",
            },
        },
        Version = 2,
        WorkspaceName = "TestWS",
    });
});Content copied to clipboard
package main
import (
	"github.com/pulumi/pulumi-azure-native-sdk/operationalinsights/v2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := operationalinsights.NewSavedSearch(ctx, "savedSearch", &operationalinsights.SavedSearchArgs{
			Category:           pulumi.String("Saved Search Test Category"),
			DisplayName:        pulumi.String("Create or Update Saved Search Test"),
			FunctionAlias:      pulumi.String("heartbeat_func"),
			FunctionParameters: pulumi.String("a:int=1"),
			Query:              pulumi.String("Heartbeat | summarize Count() by Computer | take a"),
			ResourceGroupName:  pulumi.String("TestRG"),
			SavedSearchId:      pulumi.String("00000000-0000-0000-0000-00000000000"),
			Tags: []operationalinsights.TagArgs{
				{
					Name:  pulumi.String("Group"),
					Value: pulumi.String("Computer"),
				},
			},
			Version:       pulumi.Float64(2),
			WorkspaceName: pulumi.String("TestWS"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.operationalinsights.SavedSearch;
import com.pulumi.azurenative.operationalinsights.SavedSearchArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }
    public static void stack(Context ctx) {
        var savedSearch = new SavedSearch("savedSearch", SavedSearchArgs.builder()
            .category("Saved Search Test Category")
            .displayName("Create or Update Saved Search Test")
            .functionAlias("heartbeat_func")
            .functionParameters("a:int=1")
            .query("Heartbeat | summarize Count() by Computer | take a")
            .resourceGroupName("TestRG")
            .savedSearchId("00000000-0000-0000-0000-00000000000")
            .tags(Map.ofEntries(
                Map.entry("name", "Group"),
                Map.entry("value", "Computer")
            ))
            .version(2)
            .workspaceName("TestWS")
            .build());
    }
}Content copied to clipboard
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:operationalinsights:SavedSearch myresource1 /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/savedSearches/{savedSearchId}Content copied to clipboard
Properties
Link copied to clipboard
                Link copied to clipboard
                Link copied to clipboard
                The optional function parameters if query serves as a function. Value should be in the following format: 'param-name1:type1 = default_value1, param-name2:type2 = default_value2'. For more examples and proper syntax please refer to https://docs.microsoft.com/en-us/azure/kusto/query/functions/user-defined-functions.
Link copied to clipboard