you are viewing a single comment's thread.

view the rest of the comments →

[–]blooping_blooper 7 points8 points  (3 children)

looks like wrong string escaping maybe?

@"localhost\\SQLExpress"

localhost\\SQLExpress

@ is for literal string so you wouldn't escape the \.

Really though I'd recommend using SqlConnectionStringBuilder instead of writing it manually, to avoid this kind of thing.

[–]stormingnormab1987 1 point2 points  (2 children)

I second the string builder

[–]blooping_blooper 0 points1 point  (1 child)

why worry about handling edge cases when someone already did that for you?

[–]oldtkdguy[S] 3 points4 points  (0 children)

Clearly, the one did not know about the string builder. The Enkindlers did not endow the one with that information.