1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. DatabaseManagement
  5. getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

oci.DatabaseManagement.getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

    This data source provides details about a specific Managed Database Optimizer Statistics Advisor Execution Script resource in Oracle Cloud Infrastructure Database Management service.

    Gets the Oracle system-generated script for the specified Optimizer Statistics Advisor execution.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testManagedDatabaseOptimizerStatisticsAdvisorExecutionScript = oci.DatabaseManagement.getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript({
        executionName: managedDatabaseOptimizerStatisticsAdvisorExecutionScriptExecutionName,
        managedDatabaseId: testManagedDatabase.id,
        taskName: managedDatabaseOptimizerStatisticsAdvisorExecutionScriptTaskName,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_managed_database_optimizer_statistics_advisor_execution_script = oci.DatabaseManagement.get_managed_database_optimizer_statistics_advisor_execution_script(execution_name=managed_database_optimizer_statistics_advisor_execution_script_execution_name,
        managed_database_id=test_managed_database["id"],
        task_name=managed_database_optimizer_statistics_advisor_execution_script_task_name)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/DatabaseManagement"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := DatabaseManagement.GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScript(ctx, &databasemanagement.GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs{
    			ExecutionName:     managedDatabaseOptimizerStatisticsAdvisorExecutionScriptExecutionName,
    			ManagedDatabaseId: testManagedDatabase.Id,
    			TaskName:          managedDatabaseOptimizerStatisticsAdvisorExecutionScriptTaskName,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testManagedDatabaseOptimizerStatisticsAdvisorExecutionScript = Oci.DatabaseManagement.GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScript.Invoke(new()
        {
            ExecutionName = managedDatabaseOptimizerStatisticsAdvisorExecutionScriptExecutionName,
            ManagedDatabaseId = testManagedDatabase.Id,
            TaskName = managedDatabaseOptimizerStatisticsAdvisorExecutionScriptTaskName,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.DatabaseManagement.DatabaseManagementFunctions;
    import com.pulumi.oci.DatabaseManagement.inputs.GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs;
    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) {
            final var testManagedDatabaseOptimizerStatisticsAdvisorExecutionScript = DatabaseManagementFunctions.getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript(GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs.builder()
                .executionName(managedDatabaseOptimizerStatisticsAdvisorExecutionScriptExecutionName)
                .managedDatabaseId(testManagedDatabase.id())
                .taskName(managedDatabaseOptimizerStatisticsAdvisorExecutionScriptTaskName)
                .build());
    
        }
    }
    
    variables:
      testManagedDatabaseOptimizerStatisticsAdvisorExecutionScript:
        fn::invoke:
          Function: oci:DatabaseManagement:getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript
          Arguments:
            executionName: ${managedDatabaseOptimizerStatisticsAdvisorExecutionScriptExecutionName}
            managedDatabaseId: ${testManagedDatabase.id}
            taskName: ${managedDatabaseOptimizerStatisticsAdvisorExecutionScriptTaskName}
    

    Using getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript(args: GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs, opts?: InvokeOptions): Promise<GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult>
    function getManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptOutput(args: GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptOutputArgs, opts?: InvokeOptions): Output<GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult>
    def get_managed_database_optimizer_statistics_advisor_execution_script(execution_name: Optional[str] = None,
                                                                           managed_database_id: Optional[str] = None,
                                                                           task_name: Optional[str] = None,
                                                                           opts: Optional[InvokeOptions] = None) -> GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult
    def get_managed_database_optimizer_statistics_advisor_execution_script_output(execution_name: Optional[pulumi.Input[str]] = None,
                                                                           managed_database_id: Optional[pulumi.Input[str]] = None,
                                                                           task_name: Optional[pulumi.Input[str]] = None,
                                                                           opts: Optional[InvokeOptions] = None) -> Output[GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult]
    func GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScript(ctx *Context, args *GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs, opts ...InvokeOption) (*GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult, error)
    func GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptOutput(ctx *Context, args *GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptOutputArgs, opts ...InvokeOption) GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResultOutput

    > Note: This function is named GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScript in the Go SDK.

    public static class GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScript 
    {
        public static Task<GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult> InvokeAsync(GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs args, InvokeOptions? opts = null)
        public static Output<GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult> Invoke(GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptResult> getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript(GetManagedDatabaseOptimizerStatisticsAdvisorExecutionScriptArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:DatabaseManagement/getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript:getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript
      arguments:
        # arguments dictionary

    The following arguments are supported:

    ExecutionName string
    The name of the Optimizer Statistics Advisor execution.
    ManagedDatabaseId string
    The OCID of the Managed Database.
    TaskName string
    The name of the optimizer statistics collection execution task.
    ExecutionName string
    The name of the Optimizer Statistics Advisor execution.
    ManagedDatabaseId string
    The OCID of the Managed Database.
    TaskName string
    The name of the optimizer statistics collection execution task.
    executionName String
    The name of the Optimizer Statistics Advisor execution.
    managedDatabaseId String
    The OCID of the Managed Database.
    taskName String
    The name of the optimizer statistics collection execution task.
    executionName string
    The name of the Optimizer Statistics Advisor execution.
    managedDatabaseId string
    The OCID of the Managed Database.
    taskName string
    The name of the optimizer statistics collection execution task.
    execution_name str
    The name of the Optimizer Statistics Advisor execution.
    managed_database_id str
    The OCID of the Managed Database.
    task_name str
    The name of the optimizer statistics collection execution task.
    executionName String
    The name of the Optimizer Statistics Advisor execution.
    managedDatabaseId String
    The OCID of the Managed Database.
    taskName String
    The name of the optimizer statistics collection execution task.

    getManagedDatabaseOptimizerStatisticsAdvisorExecutionScript Result

    The following output properties are available:

    ExecutionName string
    Id string
    The provider-assigned unique ID for this managed resource.
    ManagedDatabaseId string
    Script string
    The Optimizer Statistics Advisor execution script.
    TaskName string
    ExecutionName string
    Id string
    The provider-assigned unique ID for this managed resource.
    ManagedDatabaseId string
    Script string
    The Optimizer Statistics Advisor execution script.
    TaskName string
    executionName String
    id String
    The provider-assigned unique ID for this managed resource.
    managedDatabaseId String
    script String
    The Optimizer Statistics Advisor execution script.
    taskName String
    executionName string
    id string
    The provider-assigned unique ID for this managed resource.
    managedDatabaseId string
    script string
    The Optimizer Statistics Advisor execution script.
    taskName string
    execution_name str
    id str
    The provider-assigned unique ID for this managed resource.
    managed_database_id str
    script str
    The Optimizer Statistics Advisor execution script.
    task_name str
    executionName String
    id String
    The provider-assigned unique ID for this managed resource.
    managedDatabaseId String
    script String
    The Optimizer Statistics Advisor execution script.
    taskName String

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi