Really simple problem:
I want to split the connection string into my keyword / value pairs, for example, the following connection string:
Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=vm-jp-dev2;Data Source=scsql\sql2005;Auto Translate=False
It would be:
Provider=SQLOLEDB.1
Integrated Security=SSPI
Persist Security Info=False
Initial Catalog=vm-jp-dev2
Data Source=scsql\sql2005
Auto Translate=False
The problem is that the MSDN documentation claims that connection string values can contain semicolons if the value is enclosed in single or double quotation marks, (so if I understand this will be true):
Provider="Some;Provider";Initial Catalog='Some;Catalog';...
What is the best way to split this line (in C #)?
source
share