Skip to content

Commit

Permalink
Remove password (#2928)
Browse files Browse the repository at this point in the history
  • Loading branch information
cheenamalhotra authored Oct 25, 2024
1 parent 2e163b2 commit 641892c
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,13 @@
// Pass the SqlConnectionStringBuilder an existing
// connection string, and you can retrieve and
// modify any of the elements.
builder.ConnectionString = "server=(local);user id=ab;" +
"password= a!Pass113;initial catalog=AdventureWorks";
builder.ConnectionString = "server=(local);integrated security=SSPI;
initial catalog=AdventureWorks";

// Now that the connection string has been parsed,
// you can work with individual items.
Console.WriteLine(builder.Password);
builder.Password = "new@1Password";
Console.WriteLine(builder.InitialCatalog);
builder.InitialCatalog = "Northwind";

// You can refer to connection keys using strings,
// as well. When you use this technique (the default
Expand Down

0 comments on commit 641892c

Please sign in to comment.