fork(1) download
  1. using System;
  2. using System.Text.RegularExpressions;
  3.  
  4. public class Test
  5. {
  6. public static void Main()
  7. {
  8. var connStr = "Driver={SQL Server};server=.\\sqlexpress;uid=myid;pwd=password;";
  9. var res = Regex.Replace(connStr, "Driver=[{][^}]*[}];", "");
  10. Console.WriteLine(res);
  11. }
  12. }
Success #stdin #stdout 0.06s 34056KB
stdin
Standard input is empty
stdout
server=.\sqlexpress;uid=myid;pwd=password;