Connection string in vs C sharp

I have the following connection string in c#. what will be its equivalent in
@"SERVER=GAATLENDCTU123W\SQLEXPRESS; Initial Catalog=Test;Integrated Security=SSPI ";
Who is Participating?
Raja Jegan RConnect With a Mentor SQL Server DBA & ArchitectCommented:
You can use:


Complete set of options below:
YZlatConnect With a Mentor Commented:
same thing in VB.NET except you won't need @ escape character in front of the string:

dim strConn="SERVER=GAATLENDCTU123W\SQLEXPRESS; Initial Catalog=Test;Integrated Security=SSPI " 
also I'd suggest changing your connection string to the following:

"Data Source=GAATLENDCTU123W\SQLEXPRESS;Initial Catalog=Test;Integrated Security=SSPI;"

dim strConn as string="Data Source=GAATLENDCTU123W\SQLEXPRESS;Initial Catalog=Test;Integrated Security=SSPI;"
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.