Oracle Cloud Infrastructure v3.9.0 published on Wednesday, Sep 24, 2025 by Pulumi
oci.DatabaseManagement.getManagedDatabaseSqlTuningSets
This data source provides the list of Managed Database Sql Tuning Sets in Oracle Cloud Infrastructure Database Management service.
Lists the SQL tuning sets for the specified Managed Database.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testManagedDatabaseSqlTuningSets = oci.DatabaseManagement.getManagedDatabaseSqlTuningSets({
    managedDatabaseId: testManagedDatabase.id,
    nameContains: managedDatabaseSqlTuningSetNameContains,
    opcNamedCredentialId: managedDatabaseSqlTuningSetOpcNamedCredentialId,
    owner: managedDatabaseSqlTuningSetOwner,
});
import pulumi
import pulumi_oci as oci
test_managed_database_sql_tuning_sets = oci.DatabaseManagement.get_managed_database_sql_tuning_sets(managed_database_id=test_managed_database["id"],
    name_contains=managed_database_sql_tuning_set_name_contains,
    opc_named_credential_id=managed_database_sql_tuning_set_opc_named_credential_id,
    owner=managed_database_sql_tuning_set_owner)
package main
import (
	"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/databasemanagement"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := databasemanagement.GetManagedDatabaseSqlTuningSets(ctx, &databasemanagement.GetManagedDatabaseSqlTuningSetsArgs{
			ManagedDatabaseId:    testManagedDatabase.Id,
			NameContains:         pulumi.StringRef(managedDatabaseSqlTuningSetNameContains),
			OpcNamedCredentialId: pulumi.StringRef(managedDatabaseSqlTuningSetOpcNamedCredentialId),
			Owner:                pulumi.StringRef(managedDatabaseSqlTuningSetOwner),
		}, 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 testManagedDatabaseSqlTuningSets = Oci.DatabaseManagement.GetManagedDatabaseSqlTuningSets.Invoke(new()
    {
        ManagedDatabaseId = testManagedDatabase.Id,
        NameContains = managedDatabaseSqlTuningSetNameContains,
        OpcNamedCredentialId = managedDatabaseSqlTuningSetOpcNamedCredentialId,
        Owner = managedDatabaseSqlTuningSetOwner,
    });
});
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.GetManagedDatabaseSqlTuningSetsArgs;
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 testManagedDatabaseSqlTuningSets = DatabaseManagementFunctions.getManagedDatabaseSqlTuningSets(GetManagedDatabaseSqlTuningSetsArgs.builder()
            .managedDatabaseId(testManagedDatabase.id())
            .nameContains(managedDatabaseSqlTuningSetNameContains)
            .opcNamedCredentialId(managedDatabaseSqlTuningSetOpcNamedCredentialId)
            .owner(managedDatabaseSqlTuningSetOwner)
            .build());
    }
}
variables:
  testManagedDatabaseSqlTuningSets:
    fn::invoke:
      function: oci:DatabaseManagement:getManagedDatabaseSqlTuningSets
      arguments:
        managedDatabaseId: ${testManagedDatabase.id}
        nameContains: ${managedDatabaseSqlTuningSetNameContains}
        opcNamedCredentialId: ${managedDatabaseSqlTuningSetOpcNamedCredentialId}
        owner: ${managedDatabaseSqlTuningSetOwner}
Using getManagedDatabaseSqlTuningSets
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 getManagedDatabaseSqlTuningSets(args: GetManagedDatabaseSqlTuningSetsArgs, opts?: InvokeOptions): Promise<GetManagedDatabaseSqlTuningSetsResult>
function getManagedDatabaseSqlTuningSetsOutput(args: GetManagedDatabaseSqlTuningSetsOutputArgs, opts?: InvokeOptions): Output<GetManagedDatabaseSqlTuningSetsResult>def get_managed_database_sql_tuning_sets(filters: Optional[Sequence[GetManagedDatabaseSqlTuningSetsFilter]] = None,
                                         managed_database_id: Optional[str] = None,
                                         name_contains: Optional[str] = None,
                                         opc_named_credential_id: Optional[str] = None,
                                         owner: Optional[str] = None,
                                         opts: Optional[InvokeOptions] = None) -> GetManagedDatabaseSqlTuningSetsResult
def get_managed_database_sql_tuning_sets_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetManagedDatabaseSqlTuningSetsFilterArgs]]]] = None,
                                         managed_database_id: Optional[pulumi.Input[str]] = None,
                                         name_contains: Optional[pulumi.Input[str]] = None,
                                         opc_named_credential_id: Optional[pulumi.Input[str]] = None,
                                         owner: Optional[pulumi.Input[str]] = None,
                                         opts: Optional[InvokeOptions] = None) -> Output[GetManagedDatabaseSqlTuningSetsResult]func GetManagedDatabaseSqlTuningSets(ctx *Context, args *GetManagedDatabaseSqlTuningSetsArgs, opts ...InvokeOption) (*GetManagedDatabaseSqlTuningSetsResult, error)
func GetManagedDatabaseSqlTuningSetsOutput(ctx *Context, args *GetManagedDatabaseSqlTuningSetsOutputArgs, opts ...InvokeOption) GetManagedDatabaseSqlTuningSetsResultOutput> Note: This function is named GetManagedDatabaseSqlTuningSets in the Go SDK.
public static class GetManagedDatabaseSqlTuningSets 
{
    public static Task<GetManagedDatabaseSqlTuningSetsResult> InvokeAsync(GetManagedDatabaseSqlTuningSetsArgs args, InvokeOptions? opts = null)
    public static Output<GetManagedDatabaseSqlTuningSetsResult> Invoke(GetManagedDatabaseSqlTuningSetsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetManagedDatabaseSqlTuningSetsResult> getManagedDatabaseSqlTuningSets(GetManagedDatabaseSqlTuningSetsArgs args, InvokeOptions options)
public static Output<GetManagedDatabaseSqlTuningSetsResult> getManagedDatabaseSqlTuningSets(GetManagedDatabaseSqlTuningSetsArgs args, InvokeOptions options)
fn::invoke:
  function: oci:DatabaseManagement/getManagedDatabaseSqlTuningSets:getManagedDatabaseSqlTuningSets
  arguments:
    # arguments dictionaryThe following arguments are supported:
- ManagedDatabase stringId 
- The OCID of the Managed Database.
- Filters
List<GetManaged Database Sql Tuning Sets Filter> 
- NameContains string
- Allow searching the name of the SQL tuning set by partial matching. The search is case insensitive.
- OpcNamed stringCredential Id 
- The OCID of the Named Credential.
- Owner string
- The owner of the SQL tuning set.
- ManagedDatabase stringId 
- The OCID of the Managed Database.
- Filters
[]GetManaged Database Sql Tuning Sets Filter 
- NameContains string
- Allow searching the name of the SQL tuning set by partial matching. The search is case insensitive.
- OpcNamed stringCredential Id 
- The OCID of the Named Credential.
- Owner string
- The owner of the SQL tuning set.
- managedDatabase StringId 
- The OCID of the Managed Database.
- filters
List<GetManaged Database Sql Tuning Sets Filter> 
- nameContains String
- Allow searching the name of the SQL tuning set by partial matching. The search is case insensitive.
- opcNamed StringCredential Id 
- The OCID of the Named Credential.
- owner String
- The owner of the SQL tuning set.
- managedDatabase stringId 
- The OCID of the Managed Database.
- filters
GetManaged Database Sql Tuning Sets Filter[] 
- nameContains string
- Allow searching the name of the SQL tuning set by partial matching. The search is case insensitive.
- opcNamed stringCredential Id 
- The OCID of the Named Credential.
- owner string
- The owner of the SQL tuning set.
- managed_database_ strid 
- The OCID of the Managed Database.
- filters
Sequence[GetManaged Database Sql Tuning Sets Filter] 
- name_contains str
- Allow searching the name of the SQL tuning set by partial matching. The search is case insensitive.
- opc_named_ strcredential_ id 
- The OCID of the Named Credential.
- owner str
- The owner of the SQL tuning set.
- managedDatabase StringId 
- The OCID of the Managed Database.
- filters List<Property Map>
- nameContains String
- Allow searching the name of the SQL tuning set by partial matching. The search is case insensitive.
- opcNamed StringCredential Id 
- The OCID of the Named Credential.
- owner String
- The owner of the SQL tuning set.
getManagedDatabaseSqlTuningSets Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- ManagedDatabase stringId 
- The OCID of the Managed Database.
- SqlTuning List<GetSet Collections Managed Database Sql Tuning Sets Sql Tuning Set Collection> 
- The list of sql_tuning_set_collection.
- Filters
List<GetManaged Database Sql Tuning Sets Filter> 
- NameContains string
- OpcNamed stringCredential Id 
- Owner string
- The owner of the SQL tuning set.
- Id string
- The provider-assigned unique ID for this managed resource.
- ManagedDatabase stringId 
- The OCID of the Managed Database.
- SqlTuning []GetSet Collections Managed Database Sql Tuning Sets Sql Tuning Set Collection 
- The list of sql_tuning_set_collection.
- Filters
[]GetManaged Database Sql Tuning Sets Filter 
- NameContains string
- OpcNamed stringCredential Id 
- Owner string
- The owner of the SQL tuning set.
- id String
- The provider-assigned unique ID for this managed resource.
- managedDatabase StringId 
- The OCID of the Managed Database.
- sqlTuning List<GetSet Collections Managed Database Sql Tuning Sets Sql Tuning Set Collection> 
- The list of sql_tuning_set_collection.
- filters
List<GetManaged Database Sql Tuning Sets Filter> 
- nameContains String
- opcNamed StringCredential Id 
- owner String
- The owner of the SQL tuning set.
- id string
- The provider-assigned unique ID for this managed resource.
- managedDatabase stringId 
- The OCID of the Managed Database.
- sqlTuning GetSet Collections Managed Database Sql Tuning Sets Sql Tuning Set Collection[] 
- The list of sql_tuning_set_collection.
- filters
GetManaged Database Sql Tuning Sets Filter[] 
- nameContains string
- opcNamed stringCredential Id 
- owner string
- The owner of the SQL tuning set.
- id str
- The provider-assigned unique ID for this managed resource.
- managed_database_ strid 
- The OCID of the Managed Database.
- sql_tuning_ Sequence[Getset_ collections Managed Database Sql Tuning Sets Sql Tuning Set Collection] 
- The list of sql_tuning_set_collection.
- filters
Sequence[GetManaged Database Sql Tuning Sets Filter] 
- name_contains str
- opc_named_ strcredential_ id 
- owner str
- The owner of the SQL tuning set.
- id String
- The provider-assigned unique ID for this managed resource.
- managedDatabase StringId 
- The OCID of the Managed Database.
- sqlTuning List<Property Map>Set Collections 
- The list of sql_tuning_set_collection.
- filters List<Property Map>
- nameContains String
- opcNamed StringCredential Id 
- owner String
- The owner of the SQL tuning set.
Supporting Types
GetManagedDatabaseSqlTuningSetsFilter      
GetManagedDatabaseSqlTuningSetsSqlTuningSetCollection         
- Items
List<GetManaged Database Sql Tuning Sets Sql Tuning Set Collection Item> 
- The details in the SQL tuning set summary.
- Items
[]GetManaged Database Sql Tuning Sets Sql Tuning Set Collection Item 
- The details in the SQL tuning set summary.
- items
List<GetManaged Database Sql Tuning Sets Sql Tuning Set Collection Item> 
- The details in the SQL tuning set summary.
- items
GetManaged Database Sql Tuning Sets Sql Tuning Set Collection Item[] 
- The details in the SQL tuning set summary.
- items
Sequence[GetManaged Database Sql Tuning Sets Sql Tuning Set Collection Item] 
- The details in the SQL tuning set summary.
- items List<Property Map>
- The details in the SQL tuning set summary.
GetManagedDatabaseSqlTuningSetsSqlTuningSetCollectionItem          
- Description string
- The description of the SQL tuning set.
- ErrorMessage string
- Latest execution error of the plsql that was submitted as a scheduler job.
- Id int
- The unique Sql tuning set identifier. This is not OCID.
- Name string
- The name of the SQL tuning set.
- Owner string
- The owner of the SQL tuning set.
- ScheduledJob stringName 
- Name of the Sql tuning set scheduler job.
- StatementCounts int
- The number of SQL statements in the SQL tuning set.
- Status string
- Current status of the Sql tuning set.
- TimeCreated string
- The created time of the Sql tuning set.
- TimeLast stringModified 
- Last modified time of the Sql tuning set.
- Description string
- The description of the SQL tuning set.
- ErrorMessage string
- Latest execution error of the plsql that was submitted as a scheduler job.
- Id int
- The unique Sql tuning set identifier. This is not OCID.
- Name string
- The name of the SQL tuning set.
- Owner string
- The owner of the SQL tuning set.
- ScheduledJob stringName 
- Name of the Sql tuning set scheduler job.
- StatementCounts int
- The number of SQL statements in the SQL tuning set.
- Status string
- Current status of the Sql tuning set.
- TimeCreated string
- The created time of the Sql tuning set.
- TimeLast stringModified 
- Last modified time of the Sql tuning set.
- description String
- The description of the SQL tuning set.
- errorMessage String
- Latest execution error of the plsql that was submitted as a scheduler job.
- id Integer
- The unique Sql tuning set identifier. This is not OCID.
- name String
- The name of the SQL tuning set.
- owner String
- The owner of the SQL tuning set.
- scheduledJob StringName 
- Name of the Sql tuning set scheduler job.
- statementCounts Integer
- The number of SQL statements in the SQL tuning set.
- status String
- Current status of the Sql tuning set.
- timeCreated String
- The created time of the Sql tuning set.
- timeLast StringModified 
- Last modified time of the Sql tuning set.
- description string
- The description of the SQL tuning set.
- errorMessage string
- Latest execution error of the plsql that was submitted as a scheduler job.
- id number
- The unique Sql tuning set identifier. This is not OCID.
- name string
- The name of the SQL tuning set.
- owner string
- The owner of the SQL tuning set.
- scheduledJob stringName 
- Name of the Sql tuning set scheduler job.
- statementCounts number
- The number of SQL statements in the SQL tuning set.
- status string
- Current status of the Sql tuning set.
- timeCreated string
- The created time of the Sql tuning set.
- timeLast stringModified 
- Last modified time of the Sql tuning set.
- description str
- The description of the SQL tuning set.
- error_message str
- Latest execution error of the plsql that was submitted as a scheduler job.
- id int
- The unique Sql tuning set identifier. This is not OCID.
- name str
- The name of the SQL tuning set.
- owner str
- The owner of the SQL tuning set.
- scheduled_job_ strname 
- Name of the Sql tuning set scheduler job.
- statement_counts int
- The number of SQL statements in the SQL tuning set.
- status str
- Current status of the Sql tuning set.
- time_created str
- The created time of the Sql tuning set.
- time_last_ strmodified 
- Last modified time of the Sql tuning set.
- description String
- The description of the SQL tuning set.
- errorMessage String
- Latest execution error of the plsql that was submitted as a scheduler job.
- id Number
- The unique Sql tuning set identifier. This is not OCID.
- name String
- The name of the SQL tuning set.
- owner String
- The owner of the SQL tuning set.
- scheduledJob StringName 
- Name of the Sql tuning set scheduler job.
- statementCounts Number
- The number of SQL statements in the SQL tuning set.
- status String
- Current status of the Sql tuning set.
- timeCreated String
- The created time of the Sql tuning set.
- timeLast StringModified 
- Last modified time of the Sql tuning set.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.
