File tree Expand file tree Collapse file tree 4 files changed +19
-2
lines changed Expand file tree Collapse file tree 4 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -32,5 +32,6 @@ public class Constants
32
32
public const string ComputeGenerationGen5 = "Gen5" ;
33
33
public const string CollationSqlLatin1 = "SQL_Latin1_General_CP1_CI_AS" ;
34
34
public const string CollationLatin1 = "Latin1_General_100_CS_AS_SC" ;
35
+ public const string TimeZoneUtc = "UTC" ;
35
36
}
36
37
}
Original file line number Diff line number Diff line change @@ -143,11 +143,20 @@ public class NewAzureSqlManagedInstance : ManagedInstanceCmdletBase
143
143
/// Gets or sets the instance collation
144
144
/// </summary>
145
145
[ Parameter ( Mandatory = false ,
146
- HelpMessage = "The collation of the Azure SQL Managed Instance to use." ) ]
146
+ HelpMessage = "The collation of the instance to use." ) ]
147
147
[ ValidateNotNullOrEmpty ]
148
148
[ PSArgumentCompleter ( Constants . CollationSqlLatin1 , Constants . CollationLatin1 ) ]
149
149
public string Collation { get ; set ; }
150
150
151
+ /// <summary>
152
+ /// Gets or sets the instance time zone
153
+ /// </summary>
154
+ [ Parameter ( Mandatory = false ,
155
+ HelpMessage = "The time zone id for the instance to set." ) ]
156
+ [ ValidateNotNullOrEmpty ]
157
+ [ PSArgumentCompleter ( Constants . TimeZoneUtc ) ]
158
+ public string TimezoneId { get ; set ; }
159
+
151
160
/// <summary>
152
161
/// Gets or sets the tags to associate with the instance
153
162
/// </summary>
Original file line number Diff line number Diff line change @@ -97,5 +97,10 @@ public class AzureSqlManagedInstanceModel
97
97
/// Gets or sets the Managed Instance collation
98
98
/// </summary>
99
99
public string Collation { get ; set ; }
100
+
101
+ /// <summary>
102
+ /// Gets or sets the Managed Instance time zone
103
+ /// </summary>
104
+ public string TimezoneId { get ; set ; }
100
105
}
101
106
}
Original file line number Diff line number Diff line change @@ -107,7 +107,8 @@ public AzureSqlManagedInstanceModel UpsertManagedInstance(AzureSqlManagedInstanc
107
107
SubnetId = model . SubnetId ,
108
108
VCores = model . VCores ,
109
109
Identity = model . Identity ,
110
- Collation = model . Collation
110
+ Collation = model . Collation ,
111
+ TimezoneId = model . TimezoneId ,
111
112
} ) ;
112
113
113
114
return CreateManagedInstanceModelFromResponse ( resp ) ;
@@ -174,6 +175,7 @@ private static AzureSqlManagedInstanceModel CreateManagedInstanceModelFromRespon
174
175
managedInstance . VCores = resp . VCores ;
175
176
managedInstance . StorageSizeInGB = resp . StorageSizeInGB ;
176
177
managedInstance . Collation = resp . Collation ;
178
+ managedInstance . TimezoneId = resp . TimezoneId ;
177
179
178
180
Management . Internal . Resources . Models . Sku sku = new Management . Internal . Resources . Models . Sku ( ) ;
179
181
sku . Name = resp . Sku . Name ;
You can’t perform that action at this time.
0 commit comments