Solved

Adoconnection Connection String mssql custom port

Posted on 2008-10-24
8
1,594 Views
Last Modified: 2013-11-23
Hi experts,
I am having trouble finding a good connection string to use for custom mssql tcp/ip ports, not the default one (1433). My current connection string is:

Provider=SQLOLEDB.1;Password='+sedit2.Text+';Persist Security Info=True;User ID='+sedit1.Text+';Initial Catalog=GAMEDB;Data Source='+scombobox1.Text

Thanks
0
Comment
Question by:cypherbad
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 
LVL 39

Accepted Solution

by:
BrandonGalderisi earned 250 total points
ID: 22796478
servername\insteancename,portnumber

So if it's a default isntance.

servername,1234
0
 
LVL 1

Author Comment

by:cypherbad
ID: 22796498
I didn`t quite get it where to place the comma so if you can insert it in my connection string posted would be great.

Many Thanks,
Cypher
0
 
LVL 28

Assisted Solution

by:2266180
2266180 earned 250 total points
ID: 22796506
this site has saved me a bunch of times when I was in this kind of situation: http://www.connectionstrings.com/

what you need to change is:

Provider=SQLOLEDB.1;Password='+sedit2.Text+';Persist Security Info=True;User ID='+sedit1.Text+';Initial Catalog=GAMEDB;Data Source='+scombobox1.Text+','+portEdit.text
0
NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

 
LVL 28

Expert Comment

by:2266180
ID: 22796517
2 minutes too late -_-
0
 
LVL 1

Author Comment

by:cypherbad
ID: 22796519
Thanks i got it know.
0
 
LVL 1

Author Closing Comment

by:cypherbad
ID: 31509663
Thanks ciuly for the example, but since BrandonGalderisi told me the same thing but harder to understand i give to both of you half.
0
 
LVL 1

Author Comment

by:cypherbad
ID: 22796551
Congrats on your genius rank, i kinda know u from a romanian forum... :P
0
 
LVL 28

Expert Comment

by:2266180
ID: 22796571
thanks :)

tell me your username so I can ban you :drac:
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties

737 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question