|
-
Dec 4th, 2009, 09:10 AM
#1
Thread Starter
Fanatic Member
Connect 2 PC through internet
Hi every one, i have connected 2 computer via lan (using sql server)
But i want I Can access to other PC through Internet using sql server, Namely i want to access database sql on that PC. I REAd Some document about that but i am wonder , and i dont see very clearly. Can i use VPN to connect via internet or other tool ???
-
Dec 4th, 2009, 09:41 AM
#2
Re: Connect 2 PC through internet
If you use a VPN then you're on the same network, so it's as though they were both connected to the same router. If you actually want to connect over the internet then that's a configuration option in SQL Server. Connecting from VB is exactly the same as any connection; you just edit the connection string. The alternative would be a web service on the same network as the SQL Server and your app invokes that to get and save data.
-
Dec 4th, 2009, 09:53 AM
#3
Thread Starter
Fanatic Member
Re: Connect 2 PC through internet
Have you got any example about that. ex : How can you access to database on my machine if i allow. Guid me please. I NEED it very much.
-
Dec 4th, 2009, 09:59 AM
#4
Re: Connect 2 PC through internet
As I said, connecting to a database is ALWAYS the same in VB. You simply change the connection string. If you don't know the appropriate connection string then you should visit www.connectionstrings.com. How to configure a SQL Server to allow connections from the internet is not a VB.NET issue so, if you want further help on that, you should post in the Database Development forum.
-
Dec 4th, 2009, 10:03 AM
#5
Re: Connect 2 PC through internet
Also if you are behind a router or firewall, you will need to forward a port (usually 1433) to the SQL Server machine:
http://support.microsoft.com/kb/287932
-
Dec 4th, 2009, 10:05 AM
#6
Thread Starter
Fanatic Member
Re: Connect 2 PC through internet
 Originally Posted by jmcilhinney
As I said, connecting to a database is ALWAYS the same in VB. You simply change the connection string. If you don't know the appropriate connection string then you should visit www.connectionstrings.com. How to configure a SQL Server to allow connections from the internet is not a VB.NET issue so, if you want further help on that, you should post in the Database Development forum.
I tried go to that link. But i wont access success. OK.
I ll try now again. You mean. IF i want to connect to a machine which have IP address is 190.190.200.100 then i should have edit to : is it ?
Code:
Data Source=190.190.200.100,1433;Network Library=DBMSSOCN;Initial Catalog=myDataBase;User ID=myUsername;Password=myPassword;
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|