1. Registry
  2. Packages
  3. Scaleway
  4. API Docs
  5. getSdbSqlVersions
Viewing docs for Scaleway v1.60.0
published on Saturday, Oct 24, 2026 by pulumiverse
scaleway logo
Viewing docs for Scaleway v1.60.0
published on Saturday, Oct 24, 2026 by pulumiverse

    Gets information about available Serverless SQL Database versions.

    For further information refer to the Serverless SQL Databases API documentation.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as scaleway from "@pulumiverse/scaleway";
    
    const pg = scaleway.getSdbSqlVersions({
        name: "16",
    });
    const selectedVersion = pg.then(pg => pg.versions?.[0]?.name);
    
    import pulumi
    import pulumi_scaleway as scaleway
    
    pg = scaleway.get_sdb_sql_versions(name="16")
    selected_version = pg.versions[0].name
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		pg, err := scaleway.GetSdbSqlVersions(ctx, &scaleway.GetSdbSqlVersionsArgs{
    			Name: pulumi.StringRef("16"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		_ := pg.Versions[0].Name
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Scaleway = Pulumiverse.Scaleway;
    
    return await Deployment.RunAsync(() => 
    {
        var pg = Scaleway.GetSdbSqlVersions.Invoke(new()
        {
            Name = "16",
        });
    
        var selectedVersion = pg.Apply(getSdbSqlVersionsResult => getSdbSqlVersionsResult.Versions[0]?.Name);
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.scaleway.ScalewayFunctions;
    import com.pulumi.scaleway.inputs.GetSdbSqlVersionsArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    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 pg = ScalewayFunctions.getSdbSqlVersions(GetSdbSqlVersionsArgs.builder()
                .name("16")
                .build());
    
            final var selectedVersion = pg.versions()[0].name();
    
        }
    }
    
    variables:
      pg:
        fn::invoke:
          function: scaleway:getSdbSqlVersions
          arguments:
            name: '16'
      selectedVersion: ${pg.versions[0].name}
    
    pulumi {
      required_providers {
        scaleway = {
          source = "pulumi/scaleway"
        }
      }
    }
    
    data "scaleway_getsdbsqlversions" "pg" {
      name = "16"
    }
    
    locals {
      selectedVersion = data.scaleway_getsdbsqlversions.pg.versions[0].name
    }
    

    Using getSdbSqlVersions

    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 getSdbSqlVersions(args: GetSdbSqlVersionsArgs, opts?: InvokeOptions): Promise<GetSdbSqlVersionsResult>
    function getSdbSqlVersionsOutput(args: GetSdbSqlVersionsOutputArgs, opts?: InvokeOutputOptions): Output<GetSdbSqlVersionsResult>
    def get_sdb_sql_versions(name: Optional[str] = None,
                             region: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetSdbSqlVersionsResult
    def get_sdb_sql_versions_output(name: pulumi.Input[Optional[str]] = None,
                             region: pulumi.Input[Optional[str]] = None,
                             opts: Optional[InvokeOutputOptions] = None) -> Output[GetSdbSqlVersionsResult]
    func GetSdbSqlVersions(ctx *Context, args *GetSdbSqlVersionsArgs, opts ...InvokeOption) (*GetSdbSqlVersionsResult, error)
    func GetSdbSqlVersionsOutput(ctx *Context, args *GetSdbSqlVersionsOutputArgs, opts ...InvokeOption) GetSdbSqlVersionsResultOutput

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

    public static class GetSdbSqlVersions 
    {
        public static Task<GetSdbSqlVersionsResult> InvokeAsync(GetSdbSqlVersionsArgs args, InvokeOptions? opts = null)
        public static Output<GetSdbSqlVersionsResult> Invoke(GetSdbSqlVersionsInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetSdbSqlVersionsResult> Invoke(GetSdbSqlVersionsInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetSdbSqlVersionsResult> getSdbSqlVersions(GetSdbSqlVersionsArgs args, InvokeOptions options)
    public static Output<GetSdbSqlVersionsResult> getSdbSqlVersions(GetSdbSqlVersionsArgs args, InvokeOptions options)
    public static Output<GetSdbSqlVersionsResult> getSdbSqlVersions(GetSdbSqlVersionsArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: scaleway:index/getSdbSqlVersions:getSdbSqlVersions
      arguments:
        # arguments dictionary
    data "scaleway_get_sdb_sql_versions" "name" {
        # arguments
    }

    The following arguments are supported:

    Name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    Region string
    region) The region in which to list versions.
    Name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    Region string
    region) The region in which to list versions.
    name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    region string
    region) The region in which to list versions.
    name String
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    region String
    region) The region in which to list versions.
    name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    region string
    region) The region in which to list versions.
    name str
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    region str
    region) The region in which to list versions.
    name String
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    region String
    region) The region in which to list versions.

    getSdbSqlVersions Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Region string
    Versions List<Pulumiverse.Scaleway.Outputs.GetSdbSqlVersionsVersion>
    List of available Serverless SQL Database versions.
    Name string
    The major version of the PostgreSQL engine.
    Id string
    The provider-assigned unique ID for this managed resource.
    Region string
    Versions []GetSdbSqlVersionsVersion
    List of available Serverless SQL Database versions.
    Name string
    The major version of the PostgreSQL engine.
    id string
    The provider-assigned unique ID for this managed resource.
    region string
    versions list(object)
    List of available Serverless SQL Database versions.
    name string
    The major version of the PostgreSQL engine.
    id String
    The provider-assigned unique ID for this managed resource.
    region String
    versions List<GetSdbSqlVersionsVersion>
    List of available Serverless SQL Database versions.
    name String
    The major version of the PostgreSQL engine.
    id string
    The provider-assigned unique ID for this managed resource.
    region string
    versions GetSdbSqlVersionsVersion[]
    List of available Serverless SQL Database versions.
    name string
    The major version of the PostgreSQL engine.
    id str
    The provider-assigned unique ID for this managed resource.
    region str
    versions Sequence[GetSdbSqlVersionsVersion]
    List of available Serverless SQL Database versions.
    name str
    The major version of the PostgreSQL engine.
    id String
    The provider-assigned unique ID for this managed resource.
    region String
    versions List<Property Map>
    List of available Serverless SQL Database versions.
    name String
    The major version of the PostgreSQL engine.

    Supporting Types

    GetSdbSqlVersionsVersion

    EndOfLifeAt string
    End of life date of the version (RFC3339).
    Name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    Srn string
    The Scaleway Resource Name (SRN) of the version.
    EndOfLifeAt string
    End of life date of the version (RFC3339).
    Name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    Srn string
    The Scaleway Resource Name (SRN) of the version.
    end_of_life_at string
    End of life date of the version (RFC3339).
    name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    srn string
    The Scaleway Resource Name (SRN) of the version.
    endOfLifeAt String
    End of life date of the version (RFC3339).
    name String
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    srn String
    The Scaleway Resource Name (SRN) of the version.
    endOfLifeAt string
    End of life date of the version (RFC3339).
    name string
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    srn string
    The Scaleway Resource Name (SRN) of the version.
    end_of_life_at str
    End of life date of the version (RFC3339).
    name str
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    srn str
    The Scaleway Resource Name (SRN) of the version.
    endOfLifeAt String
    End of life date of the version (RFC3339).
    name String
    Filter Serverless SQL Database versions that match a given name pattern (e.g. 16).
    srn String
    The Scaleway Resource Name (SRN) of the version.

    Package Details

    Repository
    scaleway pulumiverse/pulumi-scaleway
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the scaleway Terraform Provider.
    scaleway logo
    Viewing docs for Scaleway v1.60.0
    published on Saturday, Oct 24, 2026 by pulumiverse

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial