oci.DatabaseManagement.getManagedDatabaseSqlTuningAdvisorTasksRecommendations
Explore with Pulumi AI
This data source provides the list of Managed Database Sql Tuning Advisor Tasks Recommendations in Oracle Cloud Infrastructure Database Management service.
Gets the findings and possible actions for a given object in a SQL tuning task. The task ID and object ID are used to retrieve the findings and recommendations.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testManagedDatabaseSqlTuningAdvisorTasksRecommendations = oci.DatabaseManagement.getManagedDatabaseSqlTuningAdvisorTasksRecommendations({
    executionId: testExecution.id,
    managedDatabaseId: testManagedDatabase.id,
    sqlObjectId: testObject.id,
    sqlTuningAdvisorTaskId: testSqlTuningAdvisorTask.id,
    opcNamedCredentialId: managedDatabaseSqlTuningAdvisorTasksRecommendationOpcNamedCredentialId,
});
import pulumi
import pulumi_oci as oci
test_managed_database_sql_tuning_advisor_tasks_recommendations = oci.DatabaseManagement.get_managed_database_sql_tuning_advisor_tasks_recommendations(execution_id=test_execution["id"],
    managed_database_id=test_managed_database["id"],
    sql_object_id=test_object["id"],
    sql_tuning_advisor_task_id=test_sql_tuning_advisor_task["id"],
    opc_named_credential_id=managed_database_sql_tuning_advisor_tasks_recommendation_opc_named_credential_id)
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.GetManagedDatabaseSqlTuningAdvisorTasksRecommendations(ctx, &databasemanagement.GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs{
			ExecutionId:            testExecution.Id,
			ManagedDatabaseId:      testManagedDatabase.Id,
			SqlObjectId:            testObject.Id,
			SqlTuningAdvisorTaskId: testSqlTuningAdvisorTask.Id,
			OpcNamedCredentialId:   pulumi.StringRef(managedDatabaseSqlTuningAdvisorTasksRecommendationOpcNamedCredentialId),
		}, 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 testManagedDatabaseSqlTuningAdvisorTasksRecommendations = Oci.DatabaseManagement.GetManagedDatabaseSqlTuningAdvisorTasksRecommendations.Invoke(new()
    {
        ExecutionId = testExecution.Id,
        ManagedDatabaseId = testManagedDatabase.Id,
        SqlObjectId = testObject.Id,
        SqlTuningAdvisorTaskId = testSqlTuningAdvisorTask.Id,
        OpcNamedCredentialId = managedDatabaseSqlTuningAdvisorTasksRecommendationOpcNamedCredentialId,
    });
});
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.GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs;
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 testManagedDatabaseSqlTuningAdvisorTasksRecommendations = DatabaseManagementFunctions.getManagedDatabaseSqlTuningAdvisorTasksRecommendations(GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs.builder()
            .executionId(testExecution.id())
            .managedDatabaseId(testManagedDatabase.id())
            .sqlObjectId(testObject.id())
            .sqlTuningAdvisorTaskId(testSqlTuningAdvisorTask.id())
            .opcNamedCredentialId(managedDatabaseSqlTuningAdvisorTasksRecommendationOpcNamedCredentialId)
            .build());
    }
}
variables:
  testManagedDatabaseSqlTuningAdvisorTasksRecommendations:
    fn::invoke:
      function: oci:DatabaseManagement:getManagedDatabaseSqlTuningAdvisorTasksRecommendations
      arguments:
        executionId: ${testExecution.id}
        managedDatabaseId: ${testManagedDatabase.id}
        sqlObjectId: ${testObject.id}
        sqlTuningAdvisorTaskId: ${testSqlTuningAdvisorTask.id}
        opcNamedCredentialId: ${managedDatabaseSqlTuningAdvisorTasksRecommendationOpcNamedCredentialId}
Using getManagedDatabaseSqlTuningAdvisorTasksRecommendations
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 getManagedDatabaseSqlTuningAdvisorTasksRecommendations(args: GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs, opts?: InvokeOptions): Promise<GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult>
function getManagedDatabaseSqlTuningAdvisorTasksRecommendationsOutput(args: GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsOutputArgs, opts?: InvokeOptions): Output<GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult>def get_managed_database_sql_tuning_advisor_tasks_recommendations(execution_id: Optional[str] = None,
                                                                  filters: Optional[Sequence[GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsFilter]] = None,
                                                                  managed_database_id: Optional[str] = None,
                                                                  opc_named_credential_id: Optional[str] = None,
                                                                  sql_object_id: Optional[str] = None,
                                                                  sql_tuning_advisor_task_id: Optional[str] = None,
                                                                  opts: Optional[InvokeOptions] = None) -> GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult
def get_managed_database_sql_tuning_advisor_tasks_recommendations_output(execution_id: Optional[pulumi.Input[str]] = None,
                                                                  filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsFilterArgs]]]] = None,
                                                                  managed_database_id: Optional[pulumi.Input[str]] = None,
                                                                  opc_named_credential_id: Optional[pulumi.Input[str]] = None,
                                                                  sql_object_id: Optional[pulumi.Input[str]] = None,
                                                                  sql_tuning_advisor_task_id: Optional[pulumi.Input[str]] = None,
                                                                  opts: Optional[InvokeOptions] = None) -> Output[GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult]func GetManagedDatabaseSqlTuningAdvisorTasksRecommendations(ctx *Context, args *GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs, opts ...InvokeOption) (*GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult, error)
func GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsOutput(ctx *Context, args *GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsOutputArgs, opts ...InvokeOption) GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResultOutput> Note: This function is named GetManagedDatabaseSqlTuningAdvisorTasksRecommendations in the Go SDK.
public static class GetManagedDatabaseSqlTuningAdvisorTasksRecommendations 
{
    public static Task<GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult> InvokeAsync(GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs args, InvokeOptions? opts = null)
    public static Output<GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult> Invoke(GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult> getManagedDatabaseSqlTuningAdvisorTasksRecommendations(GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs args, InvokeOptions options)
public static Output<GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsResult> getManagedDatabaseSqlTuningAdvisorTasksRecommendations(GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsArgs args, InvokeOptions options)
fn::invoke:
  function: oci:DatabaseManagement/getManagedDatabaseSqlTuningAdvisorTasksRecommendations:getManagedDatabaseSqlTuningAdvisorTasksRecommendations
  arguments:
    # arguments dictionaryThe following arguments are supported:
- ExecutionId string
- The execution ID for an execution of a SQL tuning task. This is not the OCID.
- ManagedDatabase stringId 
- The OCID of the Managed Database.
- SqlObject stringId 
- The SQL object ID for the SQL tuning task. This is not the OCID.
- SqlTuning stringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- Filters
List<GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter> 
- OpcNamed stringCredential Id 
- The OCID of the Named Credential.
- ExecutionId string
- The execution ID for an execution of a SQL tuning task. This is not the OCID.
- ManagedDatabase stringId 
- The OCID of the Managed Database.
- SqlObject stringId 
- The SQL object ID for the SQL tuning task. This is not the OCID.
- SqlTuning stringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- Filters
[]GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter 
- OpcNamed stringCredential Id 
- The OCID of the Named Credential.
- executionId String
- The execution ID for an execution of a SQL tuning task. This is not the OCID.
- managedDatabase StringId 
- The OCID of the Managed Database.
- sqlObject StringId 
- The SQL object ID for the SQL tuning task. This is not the OCID.
- sqlTuning StringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- filters
List<GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter> 
- opcNamed StringCredential Id 
- The OCID of the Named Credential.
- executionId string
- The execution ID for an execution of a SQL tuning task. This is not the OCID.
- managedDatabase stringId 
- The OCID of the Managed Database.
- sqlObject stringId 
- The SQL object ID for the SQL tuning task. This is not the OCID.
- sqlTuning stringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- filters
GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter[] 
- opcNamed stringCredential Id 
- The OCID of the Named Credential.
- execution_id str
- The execution ID for an execution of a SQL tuning task. This is not the OCID.
- managed_database_ strid 
- The OCID of the Managed Database.
- sql_object_ strid 
- The SQL object ID for the SQL tuning task. This is not the OCID.
- sql_tuning_ stradvisor_ task_ id 
- The SQL tuning task identifier. This is not the OCID.
- filters
Sequence[GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter] 
- opc_named_ strcredential_ id 
- The OCID of the Named Credential.
- executionId String
- The execution ID for an execution of a SQL tuning task. This is not the OCID.
- managedDatabase StringId 
- The OCID of the Managed Database.
- sqlObject StringId 
- The SQL object ID for the SQL tuning task. This is not the OCID.
- sqlTuning StringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- filters List<Property Map>
- opcNamed StringCredential Id 
- The OCID of the Named Credential.
getManagedDatabaseSqlTuningAdvisorTasksRecommendations Result
The following output properties are available:
- ExecutionId string
- Id string
- The provider-assigned unique ID for this managed resource.
- ManagedDatabase stringId 
- SqlObject stringId 
- SqlTuning stringAdvisor Task Id 
- The unique identifier of the task. This is not the OCID.
- SqlTuning List<GetAdvisor Task Recommendation Collections Managed Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection> 
- The list of sql_tuning_advisor_task_recommendation_collection.
- Filters
List<GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter> 
- OpcNamed stringCredential Id 
- ExecutionId string
- Id string
- The provider-assigned unique ID for this managed resource.
- ManagedDatabase stringId 
- SqlObject stringId 
- SqlTuning stringAdvisor Task Id 
- The unique identifier of the task. This is not the OCID.
- SqlTuning []GetAdvisor Task Recommendation Collections Managed Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection 
- The list of sql_tuning_advisor_task_recommendation_collection.
- Filters
[]GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter 
- OpcNamed stringCredential Id 
- executionId String
- id String
- The provider-assigned unique ID for this managed resource.
- managedDatabase StringId 
- sqlObject StringId 
- sqlTuning StringAdvisor Task Id 
- The unique identifier of the task. This is not the OCID.
- sqlTuning List<GetAdvisor Task Recommendation Collections Managed Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection> 
- The list of sql_tuning_advisor_task_recommendation_collection.
- filters
List<GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter> 
- opcNamed StringCredential Id 
- executionId string
- id string
- The provider-assigned unique ID for this managed resource.
- managedDatabase stringId 
- sqlObject stringId 
- sqlTuning stringAdvisor Task Id 
- The unique identifier of the task. This is not the OCID.
- sqlTuning GetAdvisor Task Recommendation Collections Managed Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection[] 
- The list of sql_tuning_advisor_task_recommendation_collection.
- filters
GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter[] 
- opcNamed stringCredential Id 
- execution_id str
- id str
- The provider-assigned unique ID for this managed resource.
- managed_database_ strid 
- sql_object_ strid 
- sql_tuning_ stradvisor_ task_ id 
- The unique identifier of the task. This is not the OCID.
- sql_tuning_ Sequence[Getadvisor_ task_ recommendation_ collections Managed Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection] 
- The list of sql_tuning_advisor_task_recommendation_collection.
- filters
Sequence[GetManaged Database Sql Tuning Advisor Tasks Recommendations Filter] 
- opc_named_ strcredential_ id 
- executionId String
- id String
- The provider-assigned unique ID for this managed resource.
- managedDatabase StringId 
- sqlObject StringId 
- sqlTuning StringAdvisor Task Id 
- The unique identifier of the task. This is not the OCID.
- sqlTuning List<Property Map>Advisor Task Recommendation Collections 
- The list of sql_tuning_advisor_task_recommendation_collection.
- filters List<Property Map>
- opcNamed StringCredential Id 
Supporting Types
GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsFilter        
GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsSqlTuningAdvisorTaskRecommendationCollection             
- Items
List<GetManaged Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection Item> 
- A list of SQL Tuning Advisor recommendations.
- Items
[]GetManaged Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection Item 
- A list of SQL Tuning Advisor recommendations.
- items
List<GetManaged Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection Item> 
- A list of SQL Tuning Advisor recommendations.
- items
GetManaged Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection Item[] 
- A list of SQL Tuning Advisor recommendations.
- items
Sequence[GetManaged Database Sql Tuning Advisor Tasks Recommendations Sql Tuning Advisor Task Recommendation Collection Item] 
- A list of SQL Tuning Advisor recommendations.
- items List<Property Map>
- A list of SQL Tuning Advisor recommendations.
GetManagedDatabaseSqlTuningAdvisorTasksRecommendationsSqlTuningAdvisorTaskRecommendationCollectionItem              
- Benefit double
- The percentage benefit of this implementation.
- Finding string
- Summary of the issue found in the SQL statement.
- ImplementAction stringSql 
- Action sql to be implemented based on the recommendation result.
- IsParallel boolExecution 
- Indicates whether a SQL Profile recommendation uses parallel execution.
- Rationale string
- Describes the reasoning behind the recommendation and how it relates to the finding.
- Recommendation string
- The recommendation for a specific finding.
- RecommendationKey int
- The unique identifier of the recommendation in the scope of the task.
- RecommendationType string
- Type of recommendation.
- SqlTuning stringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- SqlTuning stringAdvisor Task Object Id 
- The key of the object to which these recommendations apply. This is not the OCID.
- Benefit float64
- The percentage benefit of this implementation.
- Finding string
- Summary of the issue found in the SQL statement.
- ImplementAction stringSql 
- Action sql to be implemented based on the recommendation result.
- IsParallel boolExecution 
- Indicates whether a SQL Profile recommendation uses parallel execution.
- Rationale string
- Describes the reasoning behind the recommendation and how it relates to the finding.
- Recommendation string
- The recommendation for a specific finding.
- RecommendationKey int
- The unique identifier of the recommendation in the scope of the task.
- RecommendationType string
- Type of recommendation.
- SqlTuning stringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- SqlTuning stringAdvisor Task Object Id 
- The key of the object to which these recommendations apply. This is not the OCID.
- benefit Double
- The percentage benefit of this implementation.
- finding String
- Summary of the issue found in the SQL statement.
- implementAction StringSql 
- Action sql to be implemented based on the recommendation result.
- isParallel BooleanExecution 
- Indicates whether a SQL Profile recommendation uses parallel execution.
- rationale String
- Describes the reasoning behind the recommendation and how it relates to the finding.
- recommendation String
- The recommendation for a specific finding.
- recommendationKey Integer
- The unique identifier of the recommendation in the scope of the task.
- recommendationType String
- Type of recommendation.
- sqlTuning StringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- sqlTuning StringAdvisor Task Object Id 
- The key of the object to which these recommendations apply. This is not the OCID.
- benefit number
- The percentage benefit of this implementation.
- finding string
- Summary of the issue found in the SQL statement.
- implementAction stringSql 
- Action sql to be implemented based on the recommendation result.
- isParallel booleanExecution 
- Indicates whether a SQL Profile recommendation uses parallel execution.
- rationale string
- Describes the reasoning behind the recommendation and how it relates to the finding.
- recommendation string
- The recommendation for a specific finding.
- recommendationKey number
- The unique identifier of the recommendation in the scope of the task.
- recommendationType string
- Type of recommendation.
- sqlTuning stringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- sqlTuning stringAdvisor Task Object Id 
- The key of the object to which these recommendations apply. This is not the OCID.
- benefit float
- The percentage benefit of this implementation.
- finding str
- Summary of the issue found in the SQL statement.
- implement_action_ strsql 
- Action sql to be implemented based on the recommendation result.
- is_parallel_ boolexecution 
- Indicates whether a SQL Profile recommendation uses parallel execution.
- rationale str
- Describes the reasoning behind the recommendation and how it relates to the finding.
- recommendation str
- The recommendation for a specific finding.
- recommendation_key int
- The unique identifier of the recommendation in the scope of the task.
- recommendation_type str
- Type of recommendation.
- sql_tuning_ stradvisor_ task_ id 
- The SQL tuning task identifier. This is not the OCID.
- sql_tuning_ stradvisor_ task_ object_ id 
- The key of the object to which these recommendations apply. This is not the OCID.
- benefit Number
- The percentage benefit of this implementation.
- finding String
- Summary of the issue found in the SQL statement.
- implementAction StringSql 
- Action sql to be implemented based on the recommendation result.
- isParallel BooleanExecution 
- Indicates whether a SQL Profile recommendation uses parallel execution.
- rationale String
- Describes the reasoning behind the recommendation and how it relates to the finding.
- recommendation String
- The recommendation for a specific finding.
- recommendationKey Number
- The unique identifier of the recommendation in the scope of the task.
- recommendationType String
- Type of recommendation.
- sqlTuning StringAdvisor Task Id 
- The SQL tuning task identifier. This is not the OCID.
- sqlTuning StringAdvisor Task Object Id 
- The key of the object to which these recommendations apply. This is not the OCID.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.