Skip to content

Commit

Permalink
Changing sqlcmdvars to records because JSON.stringify can't handle Ma…
Browse files Browse the repository at this point in the history
…ps (#17683) (#17684)
  • Loading branch information
Benjin authored May 11, 2023
1 parent 4cc2604 commit 5f50530
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/services/dacFxService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export class DacFxService implements mssql.IDacFxService {
packageFilePath: packageFilePath,
databaseName: targetDatabaseName,
upgradeExisting: upgradeExisting,
sqlCommandVariableValues: sqlCommandVariableValues,
sqlCommandVariableValues: Object.fromEntries(sqlCommandVariableValues),
deploymentOptions: deploymentOptions,
ownerUri: ownerUri,
taskExecutionMode: taskExecutionMode
Expand All @@ -111,7 +111,7 @@ export class DacFxService implements mssql.IDacFxService {
const params: mssql.GenerateDeployScriptParams = {
packageFilePath: packageFilePath,
databaseName: targetDatabaseName,
sqlCommandVariableValues: sqlCommandVariableValues,
sqlCommandVariableValues: Object.fromEntries(sqlCommandVariableValues),
deploymentOptions: deploymentOptions,
ownerUri: ownerUri,
taskExecutionMode: taskExecutionMode
Expand Down Expand Up @@ -151,7 +151,7 @@ export class DacFxService implements mssql.IDacFxService {
profilePath: profilePath,
databaseName: databaseName,
connectionString: connectionString,
sqlCommandVariableValues: sqlCommandVariableValues,
sqlCommandVariableValues: Object.fromEntries(sqlCommandVariableValues),
deploymentOptions: deploymentOptions
};
return this._client.sendRequest(dacFxContracts.SavePublishProfileRequest.type, params);
Expand Down
6 changes: 3 additions & 3 deletions typings/vscode-mssql.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1112,7 +1112,7 @@ declare module 'vscode-mssql' {
packageFilePath: string;
databaseName: string;
upgradeExisting: boolean;
sqlCommandVariableValues?: Map<string, string>;
sqlCommandVariableValues?: Record<string, string>;
deploymentOptions?: DeploymentOptions;
ownerUri: string;
taskExecutionMode: TaskExecutionMode;
Expand All @@ -1121,7 +1121,7 @@ declare module 'vscode-mssql' {
export interface GenerateDeployScriptParams {
packageFilePath: string;
databaseName: string;
sqlCommandVariableValues?: Map<string, string>;
sqlCommandVariableValues?: Record<string, string>;
deploymentOptions?: DeploymentOptions;
ownerUri: string;
taskExecutionMode: TaskExecutionMode;
Expand Down Expand Up @@ -1153,7 +1153,7 @@ declare module 'vscode-mssql' {
profilePath: string;
databaseName: string;
connectionString: string;
sqlCommandVariableValues?: Map<string, string>;
sqlCommandVariableValues?: Record<string, string>;
deploymentOptions?: DeploymentOptions;
}

Expand Down

0 comments on commit 5f50530

Please sign in to comment.