Accessing SQL Server Through IP Address

Clif
Clif used Ask the Experts™
on
I am currently using the folowing connection string to connect to our SQLServer database:

m_sConnectString = "Data Source=MyServer2;Initial Catalog=MyCatalog;User Id=" & UserID & ";Password=" & Password & ";"

When I started creating my app, I did not realize that engineers in our offices out of state would need to use my app.  As such, MyServer2 doesn't mean anything to them.  So my question is, can I use the IP in the place of MyServer2 (whatever that may be)?  So my connection string would like like this (random numbers for the IP is used):

m_sConnectString = "Data Source=123.456.789.123;Initial Catalog=MyCatalog;User Id=" & UserID & ";Password=" & Password & ";"

Or is something more needed?

TIA
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Most Valuable Expert 2012
Top Expert 2014
Commented:
You can use IP as long as its accessible to them and the ports used by SQL Server are not being blocked by firewalls.

Author

Commented:
They shouldn't be, as there is another application they use that accesses the same database.

Thanks

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial