Oracle Cloud Infrastructure v3.9.0 published on Wednesday, Sep 24, 2025 by Pulumi
oci.Database.getDbVersions
This data source provides the list of Db Versions in Oracle Cloud Infrastructure Database service.
Gets a list of supported Oracle Database versions.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testDbVersions = oci.Database.getDbVersions({
compartmentId: compartmentId,
dbSystemId: testDbSystem.id,
dbSystemShape: dbVersionDbSystemShape,
isDatabaseSoftwareImageSupported: dbVersionIsDatabaseSoftwareImageSupported,
isUpgradeSupported: dbVersionIsUpgradeSupported,
shapeAttribute: dbVersionShapeAttribute,
storageManagement: dbVersionStorageManagement,
});
import pulumi
import pulumi_oci as oci
test_db_versions = oci.Database.get_db_versions(compartment_id=compartment_id,
db_system_id=test_db_system["id"],
db_system_shape=db_version_db_system_shape,
is_database_software_image_supported=db_version_is_database_software_image_supported,
is_upgrade_supported=db_version_is_upgrade_supported,
shape_attribute=db_version_shape_attribute,
storage_management=db_version_storage_management)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/database"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := database.GetDbVersions(ctx, &database.GetDbVersionsArgs{
CompartmentId: compartmentId,
DbSystemId: pulumi.StringRef(testDbSystem.Id),
DbSystemShape: pulumi.StringRef(dbVersionDbSystemShape),
IsDatabaseSoftwareImageSupported: pulumi.BoolRef(dbVersionIsDatabaseSoftwareImageSupported),
IsUpgradeSupported: pulumi.BoolRef(dbVersionIsUpgradeSupported),
ShapeAttribute: pulumi.StringRef(dbVersionShapeAttribute),
StorageManagement: pulumi.StringRef(dbVersionStorageManagement),
}, 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 testDbVersions = Oci.Database.GetDbVersions.Invoke(new()
{
CompartmentId = compartmentId,
DbSystemId = testDbSystem.Id,
DbSystemShape = dbVersionDbSystemShape,
IsDatabaseSoftwareImageSupported = dbVersionIsDatabaseSoftwareImageSupported,
IsUpgradeSupported = dbVersionIsUpgradeSupported,
ShapeAttribute = dbVersionShapeAttribute,
StorageManagement = dbVersionStorageManagement,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Database.DatabaseFunctions;
import com.pulumi.oci.Database.inputs.GetDbVersionsArgs;
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 testDbVersions = DatabaseFunctions.getDbVersions(GetDbVersionsArgs.builder()
.compartmentId(compartmentId)
.dbSystemId(testDbSystem.id())
.dbSystemShape(dbVersionDbSystemShape)
.isDatabaseSoftwareImageSupported(dbVersionIsDatabaseSoftwareImageSupported)
.isUpgradeSupported(dbVersionIsUpgradeSupported)
.shapeAttribute(dbVersionShapeAttribute)
.storageManagement(dbVersionStorageManagement)
.build());
}
}
variables:
testDbVersions:
fn::invoke:
function: oci:Database:getDbVersions
arguments:
compartmentId: ${compartmentId}
dbSystemId: ${testDbSystem.id}
dbSystemShape: ${dbVersionDbSystemShape}
isDatabaseSoftwareImageSupported: ${dbVersionIsDatabaseSoftwareImageSupported}
isUpgradeSupported: ${dbVersionIsUpgradeSupported}
shapeAttribute: ${dbVersionShapeAttribute}
storageManagement: ${dbVersionStorageManagement}
Using getDbVersions
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 getDbVersions(args: GetDbVersionsArgs, opts?: InvokeOptions): Promise<GetDbVersionsResult>
function getDbVersionsOutput(args: GetDbVersionsOutputArgs, opts?: InvokeOptions): Output<GetDbVersionsResult>def get_db_versions(compartment_id: Optional[str] = None,
db_system_id: Optional[str] = None,
db_system_shape: Optional[str] = None,
filters: Optional[Sequence[GetDbVersionsFilter]] = None,
is_database_software_image_supported: Optional[bool] = None,
is_upgrade_supported: Optional[bool] = None,
shape_attribute: Optional[str] = None,
storage_management: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDbVersionsResult
def get_db_versions_output(compartment_id: Optional[pulumi.Input[str]] = None,
db_system_id: Optional[pulumi.Input[str]] = None,
db_system_shape: Optional[pulumi.Input[str]] = None,
filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetDbVersionsFilterArgs]]]] = None,
is_database_software_image_supported: Optional[pulumi.Input[bool]] = None,
is_upgrade_supported: Optional[pulumi.Input[bool]] = None,
shape_attribute: Optional[pulumi.Input[str]] = None,
storage_management: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDbVersionsResult]func GetDbVersions(ctx *Context, args *GetDbVersionsArgs, opts ...InvokeOption) (*GetDbVersionsResult, error)
func GetDbVersionsOutput(ctx *Context, args *GetDbVersionsOutputArgs, opts ...InvokeOption) GetDbVersionsResultOutput> Note: This function is named GetDbVersions in the Go SDK.
public static class GetDbVersions
{
public static Task<GetDbVersionsResult> InvokeAsync(GetDbVersionsArgs args, InvokeOptions? opts = null)
public static Output<GetDbVersionsResult> Invoke(GetDbVersionsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetDbVersionsResult> getDbVersions(GetDbVersionsArgs args, InvokeOptions options)
public static Output<GetDbVersionsResult> getDbVersions(GetDbVersionsArgs args, InvokeOptions options)
fn::invoke:
function: oci:Database/getDbVersions:getDbVersions
arguments:
# arguments dictionaryThe following arguments are supported:
- Compartment
Id string - The compartment OCID.
- Db
System stringId - The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
- Db
System stringShape - If provided, filters the results to the set of database versions which are supported for the given shape.
- Filters
List<Get
Db Versions Filter> - Is
Database boolSoftware Image Supported - If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
- Is
Upgrade boolSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- Shape
Attribute string - If provided and applicable, return the results based on the shapeAttribute provided
- Storage
Management string - The DB system storage management option. Used to list database versions available for that storage manager. Valid values are
ASMandLVM.- ASM specifies Oracle Automatic Storage Management
- LVM specifies logical volume manager, sometimes called logical disk manager.
- Compartment
Id string - The compartment OCID.
- Db
System stringId - The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
- Db
System stringShape - If provided, filters the results to the set of database versions which are supported for the given shape.
- Filters
[]Get
Db Versions Filter - Is
Database boolSoftware Image Supported - If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
- Is
Upgrade boolSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- Shape
Attribute string - If provided and applicable, return the results based on the shapeAttribute provided
- Storage
Management string - The DB system storage management option. Used to list database versions available for that storage manager. Valid values are
ASMandLVM.- ASM specifies Oracle Automatic Storage Management
- LVM specifies logical volume manager, sometimes called logical disk manager.
- compartment
Id String - The compartment OCID.
- db
System StringId - The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
- db
System StringShape - If provided, filters the results to the set of database versions which are supported for the given shape.
- filters
List<Get
Db Versions Filter> - is
Database BooleanSoftware Image Supported - If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
- is
Upgrade BooleanSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- shape
Attribute String - If provided and applicable, return the results based on the shapeAttribute provided
- storage
Management String - The DB system storage management option. Used to list database versions available for that storage manager. Valid values are
ASMandLVM.- ASM specifies Oracle Automatic Storage Management
- LVM specifies logical volume manager, sometimes called logical disk manager.
- compartment
Id string - The compartment OCID.
- db
System stringId - The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
- db
System stringShape - If provided, filters the results to the set of database versions which are supported for the given shape.
- filters
Get
Db Versions Filter[] - is
Database booleanSoftware Image Supported - If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
- is
Upgrade booleanSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- shape
Attribute string - If provided and applicable, return the results based on the shapeAttribute provided
- storage
Management string - The DB system storage management option. Used to list database versions available for that storage manager. Valid values are
ASMandLVM.- ASM specifies Oracle Automatic Storage Management
- LVM specifies logical volume manager, sometimes called logical disk manager.
- compartment_
id str - The compartment OCID.
- db_
system_ strid - The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
- db_
system_ strshape - If provided, filters the results to the set of database versions which are supported for the given shape.
- filters
Sequence[Get
Db Versions Filter] - is_
database_ boolsoftware_ image_ supported - If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
- is_
upgrade_ boolsupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- shape_
attribute str - If provided and applicable, return the results based on the shapeAttribute provided
- storage_
management str - The DB system storage management option. Used to list database versions available for that storage manager. Valid values are
ASMandLVM.- ASM specifies Oracle Automatic Storage Management
- LVM specifies logical volume manager, sometimes called logical disk manager.
- compartment
Id String - The compartment OCID.
- db
System StringId - The DB system OCID. If provided, filters the results to the set of database versions which are supported for the DB system.
- db
System StringShape - If provided, filters the results to the set of database versions which are supported for the given shape.
- filters List<Property Map>
- is
Database BooleanSoftware Image Supported - If true, filters the results to the set of Oracle Database versions that are supported for Oracle Cloud Infrastructure database software images.
- is
Upgrade BooleanSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- shape
Attribute String - If provided and applicable, return the results based on the shapeAttribute provided
- storage
Management String - The DB system storage management option. Used to list database versions available for that storage manager. Valid values are
ASMandLVM.- ASM specifies Oracle Automatic Storage Management
- LVM specifies logical volume manager, sometimes called logical disk manager.
getDbVersions Result
The following output properties are available:
- Compartment
Id string - Db
Versions List<GetDb Versions Db Version> - The list of db_versions.
- Id string
- The provider-assigned unique ID for this managed resource.
- Db
System stringId - Db
System stringShape - Filters
List<Get
Db Versions Filter> - Is
Database boolSoftware Image Supported - Is
Upgrade boolSupported - True if this version of the Oracle Database software is supported for Upgrade.
- Shape
Attribute string - Storage
Management string
- Compartment
Id string - Db
Versions []GetDb Versions Db Version - The list of db_versions.
- Id string
- The provider-assigned unique ID for this managed resource.
- Db
System stringId - Db
System stringShape - Filters
[]Get
Db Versions Filter - Is
Database boolSoftware Image Supported - Is
Upgrade boolSupported - True if this version of the Oracle Database software is supported for Upgrade.
- Shape
Attribute string - Storage
Management string
- compartment
Id String - db
Versions List<GetDb Versions Db Version> - The list of db_versions.
- id String
- The provider-assigned unique ID for this managed resource.
- db
System StringId - db
System StringShape - filters
List<Get
Db Versions Filter> - is
Database BooleanSoftware Image Supported - is
Upgrade BooleanSupported - True if this version of the Oracle Database software is supported for Upgrade.
- shape
Attribute String - storage
Management String
- compartment
Id string - db
Versions GetDb Versions Db Version[] - The list of db_versions.
- id string
- The provider-assigned unique ID for this managed resource.
- db
System stringId - db
System stringShape - filters
Get
Db Versions Filter[] - is
Database booleanSoftware Image Supported - is
Upgrade booleanSupported - True if this version of the Oracle Database software is supported for Upgrade.
- shape
Attribute string - storage
Management string
- compartment_
id str - db_
versions Sequence[GetDb Versions Db Version] - The list of db_versions.
- id str
- The provider-assigned unique ID for this managed resource.
- db_
system_ strid - db_
system_ strshape - filters
Sequence[Get
Db Versions Filter] - is_
database_ boolsoftware_ image_ supported - is_
upgrade_ boolsupported - True if this version of the Oracle Database software is supported for Upgrade.
- shape_
attribute str - storage_
management str
- compartment
Id String - db
Versions List<Property Map> - The list of db_versions.
- id String
- The provider-assigned unique ID for this managed resource.
- db
System StringId - db
System StringShape - filters List<Property Map>
- is
Database BooleanSoftware Image Supported - is
Upgrade BooleanSupported - True if this version of the Oracle Database software is supported for Upgrade.
- shape
Attribute String - storage
Management String
Supporting Types
GetDbVersionsDbVersion
- Is
Latest boolFor Major Version - True if this version of the Oracle Database software is the latest version for a release.
- Is
Preview boolDb Version - True if this version of the Oracle Database software is the preview version.
- Is
Upgrade boolSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- Supports
Pdb bool - True if this version of the Oracle Database software supports pluggable databases.
- Version string
- A valid Oracle Database version.
- Is
Latest boolFor Major Version - True if this version of the Oracle Database software is the latest version for a release.
- Is
Preview boolDb Version - True if this version of the Oracle Database software is the preview version.
- Is
Upgrade boolSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- Supports
Pdb bool - True if this version of the Oracle Database software supports pluggable databases.
- Version string
- A valid Oracle Database version.
- is
Latest BooleanFor Major Version - True if this version of the Oracle Database software is the latest version for a release.
- is
Preview BooleanDb Version - True if this version of the Oracle Database software is the preview version.
- is
Upgrade BooleanSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- supports
Pdb Boolean - True if this version of the Oracle Database software supports pluggable databases.
- version String
- A valid Oracle Database version.
- is
Latest booleanFor Major Version - True if this version of the Oracle Database software is the latest version for a release.
- is
Preview booleanDb Version - True if this version of the Oracle Database software is the preview version.
- is
Upgrade booleanSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- supports
Pdb boolean - True if this version of the Oracle Database software supports pluggable databases.
- version string
- A valid Oracle Database version.
- is_
latest_ boolfor_ major_ version - True if this version of the Oracle Database software is the latest version for a release.
- is_
preview_ booldb_ version - True if this version of the Oracle Database software is the preview version.
- is_
upgrade_ boolsupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- supports_
pdb bool - True if this version of the Oracle Database software supports pluggable databases.
- version str
- A valid Oracle Database version.
- is
Latest BooleanFor Major Version - True if this version of the Oracle Database software is the latest version for a release.
- is
Preview BooleanDb Version - True if this version of the Oracle Database software is the preview version.
- is
Upgrade BooleanSupported - If provided, filters the results to the set of database versions which are supported for Upgrade.
- supports
Pdb Boolean - True if this version of the Oracle Database software supports pluggable databases.
- version String
- A valid Oracle Database version.
GetDbVersionsFilter
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
ociTerraform Provider.
