I have to develop an application such that i have to use the port number in the sql connection string in asp.net.How to specify the string plz help me out.
One way to do it is to connect via the IP address.
“Data Source=126.96.36.199,1433;Network Library=DBMSSOCN;Initial Catalog=Northwind;User ID=YourUser Password=YourPassGoesHere;"
(DBMSSOCN=TCP/IP instead of Named Pipes, at the end of the Data Source is the port to use (1433 is the default))
Here’s a great site for more info: http://www.connectionstrings.com/