Use Pulumi's new import command to generate code from existing cloud resources. Learn More

SqlDatabase

A sql database resource.

Example Usage

Creates a sqldatabase.

using Pulumi;
using AzureNextGen = Pulumi.AzureNextGen;

class MyStack : Stack
{
    public MyStack()
    {
        var sqlDatabase = new AzureNextGen.Synapse.V20200401Preview.SqlDatabase("sqlDatabase", new AzureNextGen.Synapse.V20200401Preview.SqlDatabaseArgs
        {
            Location = "westus",
            ResourceGroupName = "rg_88eed28c-5243-4f02-8251-bfa1e69e7057",
            SqlDatabaseName = "73164535-f22d-4daa-b014-1f23bbe361b7",
            Tags = 
            {
                { "tag1", "val1" },
            },
            WorkspaceName = "srv_85d31a1e-718b-4bda-9e53-a91230dd4ce5",
        });
    }

}
package main

import (
    synapse "github.com/pulumi/pulumi-azure-nextgen/sdk/go/azure/synapse/v20200401preview"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        _, err := synapse.NewSqlDatabase(ctx, "sqlDatabase", &synapse.SqlDatabaseArgs{
            Location:          pulumi.String("westus"),
            ResourceGroupName: pulumi.String("rg_88eed28c-5243-4f02-8251-bfa1e69e7057"),
            SqlDatabaseName:   pulumi.String("73164535-f22d-4daa-b014-1f23bbe361b7"),
            Tags: pulumi.StringMap{
                "tag1": pulumi.String("val1"),
            },
            WorkspaceName: pulumi.String("srv_85d31a1e-718b-4bda-9e53-a91230dd4ce5"),
        })
        if err != nil {
            return err
        }
        return nil
    })
}
import pulumi
import pulumi_azure_nextgen as azure_nextgen

sql_database = azure_nextgen.synapse.v20200401preview.SqlDatabase("sqlDatabase",
    location="westus",
    resource_group_name="rg_88eed28c-5243-4f02-8251-bfa1e69e7057",
    sql_database_name="73164535-f22d-4daa-b014-1f23bbe361b7",
    tags={
        "tag1": "val1",
    },
    workspace_name="srv_85d31a1e-718b-4bda-9e53-a91230dd4ce5")
import * as pulumi from "@pulumi/pulumi";
import * as azure_nextgen from "@pulumi/azure-nextgen";

const sqlDatabase = new azure_nextgen.synapse.v20200401preview.SqlDatabase("sqlDatabase", {
    location: "westus",
    resourceGroupName: "rg_88eed28c-5243-4f02-8251-bfa1e69e7057",
    sqlDatabaseName: "73164535-f22d-4daa-b014-1f23bbe361b7",
    tags: {
        tag1: "val1",
    },
    workspaceName: "srv_85d31a1e-718b-4bda-9e53-a91230dd4ce5",
});

Create a SqlDatabase Resource

new SqlDatabase(name: string, args: SqlDatabaseArgs, opts?: CustomResourceOptions);
def SqlDatabase(resource_name: str, opts: Optional[ResourceOptions] = None, collation: Optional[str] = None, location: Optional[str] = None, max_size_bytes: Optional[float] = None, resource_group_name: Optional[str] = None, sql_database_name: Optional[str] = None, tags: Optional[Mapping[str, str]] = None, workspace_name: Optional[str] = None)
func NewSqlDatabase(ctx *Context, name string, args SqlDatabaseArgs, opts ...ResourceOption) (*SqlDatabase, error)
public SqlDatabase(string name, SqlDatabaseArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args SqlDatabaseArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args SqlDatabaseArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args SqlDatabaseArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

SqlDatabase Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The SqlDatabase resource accepts the following input properties:

Location string
The geo-location where the resource lives
ResourceGroupName string
The name of the resource group. The name is case insensitive.
SqlDatabaseName string
The name of the sql database.
WorkspaceName string
The name of the workspace.
Collation string
The collation of the database.
MaxSizeBytes double
The max size of the database expressed in bytes.
Tags Dictionary<string, string>
Resource tags.
Location string
The geo-location where the resource lives
ResourceGroupName string
The name of the resource group. The name is case insensitive.
SqlDatabaseName string
The name of the sql database.
WorkspaceName string
The name of the workspace.
Collation string
The collation of the database.
MaxSizeBytes float64
The max size of the database expressed in bytes.
Tags map[string]string
Resource tags.
location string
The geo-location where the resource lives
resourceGroupName string
The name of the resource group. The name is case insensitive.
sqlDatabaseName string
The name of the sql database.
workspaceName string
The name of the workspace.
collation string
The collation of the database.
maxSizeBytes number
The max size of the database expressed in bytes.
tags {[key: string]: string}
Resource tags.
location str
The geo-location where the resource lives
resource_group_name str
The name of the resource group. The name is case insensitive.
sql_database_name str
The name of the sql database.
workspace_name str
The name of the workspace.
collation str
The collation of the database.
max_size_bytes float
The max size of the database expressed in bytes.
tags Mapping[str, str]
Resource tags.

Outputs

All input properties are implicitly available as output properties. Additionally, the SqlDatabase resource produces the following output properties:

DatabaseGuid string
The Guid of the database.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The name of the resource
Status string
Status of the database.
SystemData Pulumi.AzureNextGen.Synapse.Outputs.SystemDataResponse
SystemData of SqlDatabase.
Type string
The type of the resource. E.g. “Microsoft.Compute/virtualMachines” or “Microsoft.Storage/storageAccounts”
DatabaseGuid string
The Guid of the database.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The name of the resource
Status string
Status of the database.
SystemData SystemDataResponse
SystemData of SqlDatabase.
Type string
The type of the resource. E.g. “Microsoft.Compute/virtualMachines” or “Microsoft.Storage/storageAccounts”
databaseGuid string
The Guid of the database.
id string
The provider-assigned unique ID for this managed resource.
name string
The name of the resource
status string
Status of the database.
systemData SystemDataResponse
SystemData of SqlDatabase.
type string
The type of the resource. E.g. “Microsoft.Compute/virtualMachines” or “Microsoft.Storage/storageAccounts”
database_guid str
The Guid of the database.
id str
The provider-assigned unique ID for this managed resource.
name str
The name of the resource
status str
Status of the database.
system_data SystemDataResponse
SystemData of SqlDatabase.
type str
The type of the resource. E.g. “Microsoft.Compute/virtualMachines” or “Microsoft.Storage/storageAccounts”

Supporting Types

SystemDataResponse

CreatedAt string
The timestamp of resource creation (UTC).
CreatedBy string
A string identifier for the identity that created the resource.
CreatedByType string
The type of identity that created the resource:
LastModifiedAt string
The timestamp of last modification (UTC).
LastModifiedBy string
A string identifier for the identity that last modified the resource.
LastModifiedByType string
The type of identity that last modified the resource:
CreatedAt string
The timestamp of resource creation (UTC).
CreatedBy string
A string identifier for the identity that created the resource.
CreatedByType string
The type of identity that created the resource:
LastModifiedAt string
The timestamp of last modification (UTC).
LastModifiedBy string
A string identifier for the identity that last modified the resource.
LastModifiedByType string
The type of identity that last modified the resource:
createdAt string
The timestamp of resource creation (UTC).
createdBy string
A string identifier for the identity that created the resource.
createdByType string
The type of identity that created the resource:
lastModifiedAt string
The timestamp of last modification (UTC).
lastModifiedBy string
A string identifier for the identity that last modified the resource.
lastModifiedByType string
The type of identity that last modified the resource:
created_at str
The timestamp of resource creation (UTC).
created_by str
A string identifier for the identity that created the resource.
created_by_type str
The type of identity that created the resource:
last_modified_at str
The timestamp of last modification (UTC).
last_modified_by str
A string identifier for the identity that last modified the resource.
last_modified_by_type str
The type of identity that last modified the resource:

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-nextgen:synapse/v20200401preview:SqlDatabase 73164535-f22d-4daa-b014-1f23bbe361b7 /subscriptions/d9e39bed-00e1-4f5e-883e-6d94be335056/resourceGroups/rg_88eed28c-5243-4f02-8251-bfa1e69e7057/providers/Microsoft.Synapse/workspaces/srv_85d31a1e-718b-4bda-9e53-a91230dd4ce5/sqlDatabases/73164535-f22d-4daa-b014-1f23bbe361b7 

Package Details

Repository
https://github.com/pulumi/pulumi-azure-nextgen
License
Apache-2.0