You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -37,78 +37,30 @@ The **SqlPackage.exe** command line tool allows you to specify these actions alo
37
37
38
38
## Command-Line Syntax
39
39
40
-
**SqlPackage.exe** initiates the actions specified using the parameters, properties, and SQLCMD variables specified on the command line.
40
+
**SqlPackage.exe** initiates the actions specified using the [parameters](#parameters), [properties](#properties), and SQLCMD variables specified on the command line.
The DacFx library and the SqlPackage CLI tool have adopted the [Microsoft Modern Lifecycle Policy](https://support.microsoft.com/help/30881/modern-lifecycle-policy). All security updates, fixes, and new features will be released only in the latest point version of the major version. Maintaining your DacFx or SqlPackage installations to the current version helps ensure that you will receive all applicable bug fixes in a timely manner.
48
+
SqlPackage commands return the following exit codes:
74
49
75
-
### Supported SQL offerings
76
-
77
-
SqlPackage and DacFx supports all [supported SQL versions](/lifecycle/products/?products=sql-server) at time of the SqlPackage/DacFx release. For example, a SqlPackage release on January 14th 2022 supports all supported versions of SQL in January 14th 2022. For more on SQL support policies, see [the SQL support policy](/troubleshoot/sql/general/support-policy-sql-server#support-policy).
78
-
79
-
80
-
81
-
82
-
## Version
83
-
84
-
Displays the sqlpackage version as a build number. Can be used in interactive prompts as well as in [automated pipelines](sqlpackage-pipelines.md).
85
-
86
-
```cmd
87
-
sqlpackage.exe /Version
88
-
```
89
-
90
-
## Help
50
+
- 0 = success
51
+
- non-zero = failure
91
52
92
-
You can display SqlPackage usage information by using `/?` or `/help:True`.
53
+
### Usage example
93
54
94
-
```cmd
95
-
sqlpackage.exe /?
96
-
```
55
+
Further examples are available on the individual action pages.
97
56
98
-
For parameter and property information specific to a particular action, use the help parameter in addition to that action's parameter.
57
+
**Creating a .dacpac file of the current database schema:**
Some parameters are shared between the SqlPackage actions. Below is a table summarizing the parameters, for more information click into the specific action pages.
114
66
@@ -149,135 +101,48 @@ Some parameters are shared between the SqlPackage actions. Below is a table summ
149
101
|**/UniversalAuthentication:**|**/ua**| x | x | x | x | x | x | x |
150
102
|**/Variables:**|**/v**||||| x || x |
151
103
152
-
## Properties
153
-
154
-
Some properties are shared between the SqlPackage actions. Below is a table summarizing the properties, for more information click into the specific action pages.
|AdditionalDeploymentContributorArguments=(STRING)|| x ||| x | x |
159
-
|AdditionalDeploymentContributors=(STRING)|| x ||| x | x |
160
-
|AdditionalDeploymentContributorPaths=(STRING)|| x ||| x | x |
161
-
|AllowDropBlockingAssemblies=(BOOLEAN)|| x ||| x | x |
162
-
|AllowIncompatiblePlatform=(BOOLEAN)|| x ||| x | x |
163
-
|AllowUnsafeRowLevelSecurityDataMovement=(BOOLEAN)|| x ||| x | x |
164
-
|AzureSharedAccessSignatureToken=(STRING)|| x |||||
165
-
|AzureStorageBlobEndpoint=(STRING)| x | x |||||
166
-
|AzureStorageContainer=(STRING)| x | x |||||
167
-
|AzureStorageKey=(STRING)| x | x |||||
168
-
|AzureStorageRootPath=(STRING)| x | x |||||
169
-
|BackupDatabaseBeforeChanges=(BOOLEAN)|| x ||| x | x |
170
-
|BlockOnPossibleDataLoss=(BOOLEAN 'True')|| x ||| x | x |
171
-
|BlockWhenDriftDetected=(BOOLEAN 'True')|| x ||| x | x |
172
-
|CommandTimeout=(INT32 '60')| x | x | x | x | x | x |
173
-
|CommentOutSetVarDeclarations=(BOOLEAN)|| x ||| x | x |
174
-
|CompareUsingTargetCollation=(BOOLEAN)|| x ||| x | x |
175
-
|CompressionOption=(ENUM 'Normal')| x || x ||||
176
-
|CreateNewDatabase=(BOOLEAN)|| x ||| x | x |
177
-
|DacApplicationDescription=(STRING)| x ||||||
178
-
|DacApplicationName=(STRING)| x ||||||
179
-
|DacMajorVersion=(INT32 '1')| x ||||||
180
-
|DacMinorVersion=(INT32 '0')| x ||||||
181
-
|DatabaseEdition=(ENUM 'Default')|| x || x | x | x |
182
-
|DatabaseLockTimeout=(INT32 '60')| x | x | x || x | x |
183
-
|DatabaseMaximumSize=(INT32)|| x || x | x | x |
184
-
|DatabaseServiceObjective=(STRING)|| x || x | x | x |
185
-
|DeployDatabaseInSingleUserMode=(BOOLEAN)|| x ||| x | x |
186
-
|DisableAndReenableDdlTriggers=(BOOLEAN 'True')|| x ||| x | x |
187
-
|DisableIndexesForDataPhase=(BOOLEAN 'True')|||| x |||
188
-
|DoNotAlterChangeDataCaptureObjects=(BOOLEAN 'True')|| x ||| x | x |
189
-
|DoNotAlterReplicatedObjects=(BOOLEAN 'True')|| x ||| x | x |
190
-
|DoNotDropObjectType=(STRING)|| x ||| x | x |
191
-
|DoNotDropObjectTypes=(STRING)|| x ||| x | x |
192
-
|DropConstraintsNotInSource=(BOOLEAN 'True')|| x ||| x | x |
193
-
|DropDmlTriggersNotInSource=(BOOLEAN 'True')|| x ||| x | x |
194
-
|DropExtendedPropertiesNotInSource=(BOOLEAN 'True')|| x ||| x | x |
195
-
|DropIndexesNotInSource=(BOOLEAN 'True')|| x ||| x | x |
196
-
|DropObjectsNotInSource=(BOOLEAN)|| x ||| x | x |
197
-
|DropPermissionsNotInSource=(BOOLEAN)|| x ||| x | x |
198
-
|DropRoleMembersNotInSource=(BOOLEAN)|| x ||| x | x |
199
-
|DropStatisticsNotInSource=(BOOLEAN 'True')|| x ||| x | x |
200
-
|EnclaveAttestationProtocol=(STRING)|| x |||||
201
-
|EnclaveAttestationUrl=(STRING)|| x |||||
202
-
|ExcludeObjectType=(STRING)|| x ||| x | x |
203
-
|ExcludeObjectTypes=(STRING)|| x ||| x | x |
204
-
|ExtractAllTableData=(BOOLEAN)| x ||||||
205
-
|ExtractApplicationScopedObjectsOnly=(BOOLEAN 'True')| x ||||||
206
-
|ExtractReferencedServerScopedElements=(BOOLEAN 'True')| x ||||||
207
-
|ExtractUsageProperties=(BOOLEAN)| x ||||||
208
-
|GenerateSmartDefaults=(BOOLEAN)|| x ||| x | x |
209
-
|IgnoreAnsiNulls=(BOOLEAN 'True')|| x ||| x | x |
210
-
|IgnoreAuthorizer=(BOOLEAN)|| x ||| x | x |
211
-
|IgnoreColumnCollation=(BOOLEAN)||||| x | x |
212
-
|IgnoreColumnOrder=(BOOLEAN)|| x ||| x | x |
213
-
|IgnoreComments=(BOOLEAN)|| x ||| x | x |
214
-
|IgnoreCryptographicProviderFilePath=(BOOLEAN 'True')|| x ||| x | x |
215
-
|IgnoreDdlTriggerOrder=(BOOLEAN)|| x ||| x | x |
216
-
|IgnoreDdlTriggerState=(BOOLEAN)|| x ||| x | x |
217
-
|IgnoreDefaultSchema=(BOOLEAN)|| x ||| x | x |
218
-
|IgnoreDmlTriggerOrder=(BOOLEAN)|| x ||| x | x |
219
-
|IgnoreDmlTriggerState=(BOOLEAN)|| x ||| x | x |
220
-
|IgnoreExtendedProperties=(BOOLEAN)| x | x ||| x | x |
221
-
|IgnoreFileAndLogFilePath=(BOOLEAN 'True')|| x ||| x | x |
222
-
|IgnoreFilegroupPlacement=(BOOLEAN 'True')|| x ||| x | x |
223
-
|IgnoreFileSize=(BOOLEAN 'True')|| x ||| x | x |
224
-
|IgnoreFillFactor=(BOOLEAN 'True')|| x ||| x | x |
225
-
|IgnoreFullTextCatalogFilePath=(BOOLEAN 'True')|| x ||| x | x |
226
-
|IgnoreIdentitySeed=(BOOLEAN)|| x ||| x | x |
227
-
|IgnoreIncrement=(BOOLEAN)|| x ||| x | x |
228
-
|IgnoreIndexOptions=(BOOLEAN)|| x ||| x | x |
229
-
|IgnoreIndexPadding=(BOOLEAN 'True')|| x ||| x | x |
230
-
|IgnoreKeywordCasing=(BOOLEAN 'True')|| x ||| x | x |
231
-
|IgnoreLockHintsOnIndexes=(BOOLEAN)|| x ||| x | x |
232
-
|IgnoreLoginSids=(BOOLEAN 'True')|| x ||| x | x |
233
-
|IgnoreNotForReplication=(BOOLEAN)|| x ||| x | x |
234
-
|IgnoreObjectPlacementOnPartitionScheme=(BOOLEAN 'True')|| x ||| x | x |
235
-
|IgnorePartitionSchemes=(BOOLEAN)|| x ||| x | x |
236
-
|IgnorePermissions=(BOOLEAN 'True')| x | x ||| x | x |
237
-
|IgnoreQuotedIdentifiers=(BOOLEAN 'True')|| x ||| x | x |
238
-
|IgnoreRoleMembership=(BOOLEAN)|| x ||| x | x |
239
-
|IgnoreRouteLifetime=(BOOLEAN 'True')|| x ||| x | x |
240
-
|IgnoreSemicolonBetweenStatements=(BOOLEAN 'True')|| x ||| x | x |
241
-
|IgnoreTableOptions=(BOOLEAN)|| x ||| x | x |
242
-
|IgnoreTablePartitionOptions=(BOOLEAN)|| x ||| x | x |
243
-
|IgnoreUserLoginMappings=(BOOLEAN)| x ||||||
244
-
|IgnoreUserSettingsObjects=(BOOLEAN)|| x ||| x | x |
245
-
|IgnoreWhitespace=(BOOLEAN 'True')|| x ||| x | x |
246
-
|IgnoreWithNocheckOnCheckConstraints=(BOOLEAN)|| x ||| x ||
247
-
|IgnoreWithNocheckOnForeignKeys=(BOOLEAN)|| x ||| x ||
248
-
|ImportContributorArguments=(STRING)|||| x |||
249
-
|ImportContributors=(STRING)|||| x |||
250
-
|ImportContributorPaths=(STRING)|||| x |||
251
-
|IncludeCompositeObjects=(BOOLEAN)|| x ||| x | x |
252
-
|IncludeTransactionalScripts=(BOOLEAN)|| x ||| x | x |
253
-
|LongRunningCommandTimeout=(INT32 '0')| x | x | x | x | x | x |
254
-
|NoAlterStatementsToChangeClrTypes=(BOOLEAN)|| x ||| x | x |
255
-
|PopulateFilesOnFileGroups=(BOOLEAN 'True')|| x ||| x | x |
256
-
|RebuildIndexesOfflineForDataPhase=(BOOLEAN 'False')|||| x |||
257
-
|RegisterDataTierApplication=(BOOLEAN)|| x ||| x | x |
258
-
|RunDeploymentPlanExecutors=(BOOLEAN)|| x ||| x | x |
259
-
|ScriptDatabaseCollation=(BOOLEAN)|| x ||| x | x |
260
-
|ScriptDatabaseCompatibility=(BOOLEAN)|| x ||| x | x |
261
-
|ScriptDatabaseOptions=(BOOLEAN 'True')|| x ||| x | x |
262
-
|ScriptDeployStateChecks=(BOOLEAN)|| x ||| x | x |
263
-
|ScriptFileSize=(BOOLEAN)|| x ||| x | x |
264
-
|ScriptNewConstraintValidation=(BOOLEAN 'True')|| x ||| x | x |
265
-
|ScriptRefreshModule=(BOOLEAN 'True')|| x ||| x | x |
266
-
|Storage=({File|Memory})| x | x | x | x | x | x |
267
-
|TableData=(STRING)| x || x ||||
268
-
|TargetEngineVersion=(ENUM 'Latest')||| x ||||
269
-
|TempDirectoryForTableData=(STRING)| x || x ||||
270
-
|TreatVerificationErrorsAsWarnings=(BOOLEAN)|| x ||| x | x |
271
-
|UnmodifiableObjectWarnings=(BOOLEAN 'True')|| x ||| x | x |
272
-
|VerifyCollationCompatibility=(BOOLEAN 'True')|| x ||| x | x |
273
-
|VerifyDeployment=(BOOLEAN 'True')|| x ||| x | x |
274
-
|VerifyExtraction=(BOOLEAN)| x ||||||
275
-
|VerifyFullTextDocumentTypesSupported=(BOOLEAN)||| x ||||
104
+
### Properties
105
+
106
+
SqlPackage actions support a large number of properties to modify the default behavior of an action. For more information click into the specific action pages.
107
+
108
+
109
+
## Utility commands
110
+
111
+
### Version
112
+
113
+
Displays the sqlpackage version as a build number. Can be used in interactive prompts as well as in [automated pipelines](sqlpackage-pipelines.md).
114
+
115
+
```cmd
116
+
sqlpackage.exe /Version
117
+
```
118
+
119
+
### Help
120
+
121
+
You can display SqlPackage usage information by using `/?` or `/help:True`.
122
+
123
+
```cmd
124
+
sqlpackage.exe /?
125
+
```
126
+
127
+
For parameter and property information specific to a particular action, use the help parameter in addition to that action's parameter.
128
+
129
+
```cmd
130
+
sqlpackage.exe /Action:Publish /?
131
+
```
276
132
277
133
## SqlPackage and database users
278
134
279
135
[Contained database users](../../relational-databases/security/contained-database-users-making-your-database-portable.md) are included in SqlPackage operations. However, the password portion of the definition is set to a randomly generated string by SqlPackage, the existing value is not transferred. It is recommended that the new user's password is reset to a secure value following the import of a `.bacpac` or the deployment of a `.dacpac`. In an automated environment the password values can be retrieved from a secure keystore, such as Azure Key Vault, in a step following SqlPackage.
280
136
137
+
138
+
## Support
139
+
140
+
The DacFx library and the SqlPackage CLI tool have adopted the [Microsoft Modern Lifecycle Policy](https://support.microsoft.com/help/30881/modern-lifecycle-policy). All security updates, fixes, and new features will be released only in the latest point version of the major version. Maintaining your DacFx or SqlPackage installations to the current version helps ensure that you will receive all applicable bug fixes in a timely manner.
141
+
142
+
### Supported SQL offerings
143
+
144
+
SqlPackage and DacFx supports all [supported SQL versions](/lifecycle/products/?products=sql-server) at time of the SqlPackage/DacFx release. For example, a SqlPackage release on January 14th 2022 supports all supported versions of SQL in January 14th 2022. For more on SQL support policies, see [the SQL support policy](/troubleshoot/sql/general/support-policy-sql-server#support-policy).
145
+
281
146
## Next steps
282
147
283
148
- Learn more about [SqlPackage Extract](sqlpackage-extract.md)
0 commit comments