|
code
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Database connection/Access helpMy app needs to be installed in 3 locations A,B and C.
All three locations will use either MSDE or SSQL and have Broadband Internet with static IPs. I want to design the app so user will be able to search and update database in three locations from either location (A,B or C). My problem is how to connect to three databases via Internet and if possible phone modem... Can anyone give some clue... point me to resources/websites/books. I will appreciate any help. Thanks in advance. Using ADO to handle the Database Stuff
Dim cnA as ADODB.Connection, cnB as ADODB.Connection, cnC as ADODB.Connection Dim strCNA as String, strCNB as String, strCNC as String Set cnA = New ADODB.Connection Set cnB = New ADODB.Connection Set cnC = New ADODB.Connection strCNA = "Provider=SQLOLEDB.1; Network Library=dbmssocn; " _ & "Password=password;User ID=DbUsername;" _ & Initial Catalog=DatabaseName;Data Source=IPAddressForServerA;" strCNB = "Provider=SQLOLEDB.1; Network Library=dbmssocn; " _ & "Password=password;User ID=DbUsername;" _ & Initial Catalog=DatabaseName;Data Source=IPAddressForServerB;" strCNB = "Provider=SQLOLEDB.1; Network Library=dbmssocn; " _ & "Password=password;User ID=DbUsername;" _ & Initial Catalog=DatabaseName;Data Source=IPAddressForServerC;" cnA.Open strCNA cnB.Open strCNB cnC.Open strCNC ' You now have a Connection open to all three databases ' do what ever you want to do with the data therein ' When you are done close and dispose cnA.Close cnB.Close cnC.Close Set cnA = Nothing Set cnB = Nothing Set cnC = Nothing Be aware that the performance might not be all that good depending on the quality of the broadband connections, and all of your data will be sent over the internet in the clear. A better soultion might be to use a single Terminal Server (or Citrix) at one of your locations and have the other two locations using remote sessions to manulipate the data. I suspect that the performance will be MUCH better and you will have ALL of the data in ONE place where you can insure that it is protected, and backed up. As a bonus remote control applications perform well even when using phone dial up connections. Just my $.02. Show quoteHide quote "JP Bless" <jp3BlessNoSpam@hotmail.com> wrote in message news:eye1p3zJGHA.1180@TK2MSFTNGP09.phx.gbl... > My app needs to be installed in 3 locations A,B and C. > All three locations will use either MSDE or SSQL and have Broadband > Internet with static IPs. I want to design the app so user will be able > to search and update database in three locations from either location > (A,B or C). My problem is how to connect to three databases via Internet > and if possible phone modem... > Can anyone give some clue... point me to resources/websites/books. > I will appreciate any help. Thanks in advance. > > Thanks Ron... I appreciate the tip
Show quoteHide quote "Ron Weiner" <weinNoSpam1@mindspring.com> wrote in message news:%23N7RsRMKGHA.1320@TK2MSFTNGP15.phx.gbl... > Using ADO to handle the Database Stuff > > Dim cnA as ADODB.Connection, cnB as ADODB.Connection, cnC as > ADODB.Connection > Dim strCNA as String, strCNB as String, strCNC as String > Set cnA = New ADODB.Connection > Set cnB = New ADODB.Connection > Set cnC = New ADODB.Connection > strCNA = "Provider=SQLOLEDB.1; Network Library=dbmssocn; " _ > & "Password=password;User ID=DbUsername;" _ > & Initial Catalog=DatabaseName;Data Source=IPAddressForServerA;" > strCNB = "Provider=SQLOLEDB.1; Network Library=dbmssocn; " _ > & "Password=password;User ID=DbUsername;" _ > & Initial Catalog=DatabaseName;Data Source=IPAddressForServerB;" > strCNB = "Provider=SQLOLEDB.1; Network Library=dbmssocn; " _ > & "Password=password;User ID=DbUsername;" _ > & Initial Catalog=DatabaseName;Data Source=IPAddressForServerC;" > cnA.Open strCNA > cnB.Open strCNB > cnC.Open strCNC > ' You now have a Connection open to all three databases > ' do what ever you want to do with the data therein > ' When you are done close and dispose > cnA.Close > cnB.Close > cnC.Close > Set cnA = Nothing > Set cnB = Nothing > Set cnC = Nothing > > Be aware that the performance might not be all that good depending on the > quality of the broadband connections, and all of your data will be sent over > the internet in the clear. > > A better soultion might be to use a single Terminal Server (or Citrix) at > one of your locations and have the other two locations using remote sessions > to manulipate the data. I suspect that the performance will be MUCH better > and you will have ALL of the data in ONE place where you can insure that it > is protected, and backed up. As a bonus remote control applications perform > well even when using phone dial up connections. Just my $.02. > > -- > Ron W > www.WorksRite.com > "JP Bless" <jp3BlessNoSpam@hotmail.com> wrote in message > news:eye1p3zJGHA.1180@TK2MSFTNGP09.phx.gbl... > > My app needs to be installed in 3 locations A,B and C. > > All three locations will use either MSDE or SSQL and have Broadband > > Internet with static IPs. I want to design the app so user will be able > > to search and update database in three locations from either location > > (A,B or C). My problem is how to connect to three databases via Internet > > and if possible phone modem... > > Can anyone give some clue... point me to resources/websites/books. > > I will appreciate any help. Thanks in advance. > > > > > >
Change language keyboard
WebBrowser1.Document.Links System Error &H80004015 (-2147467243) running VB6 IDE ActiveX DLL Intercepting File read/write request from any program active desktop Order By Show all connections VB.net determining when shell command finishes Choosing source from video capture card |
|||||||||||||||||||||||