Connecting to a remote SQL DB

Hi,

 I need to connect to a remote SQLserver outside my local network. The Server is on the Internet. i played arround with the Midware Package but didn't succeed.

I'am looking for some pointers or idea's to create the connection, it has to be very stable and secure.

Hope somebody has done this before and is willing to help.

Regards,

Yuri
muldeyurAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

manjushanCommented:
Use ado connection.Build the connection string.Use ADO tables and ADO queries.
   Good luck.
               Manju.
0
muldeyurAuthor Commented:
Thankx ManjusHan,

Do you have a Code example?
I alway's worked with Odbc.

Cheers,

Yuri
0
manjushanCommented:
ADO-Active data objects also use ODBC.If ur using Delphi 5 u will have ADO components. ADO Connection is availabe through which u can build ur connection string. If ur using > Delphi 5.Then use ADODB_TLB. U have a _connection class.
 Set the connection string something like this
  ConnectionString := 'mydatabase'
  Connection.Open(ConnectionString,username,password)

for SQLServer it will look like his
   Connectionstring := 'Provider=MSDASQL.1;Persist Security Info=False;User ID=sa;Data Source=mydata'

U have a connection.Then use _RecordSet to open tables.For detailed info search for ADO in any Delphi site.
                 Good luck.
                   Manju.
                           
0
Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

muldeyurAuthor Commented:
Thankx, i'am using delphi4,
but i can usethe Ado typlib. Would it be possible to set up a dsn to a remote sql server?
0
manjushanCommented:
Sure u can connect to a remote server using Ado typ lib.
User connection string will look like this

ConnectionString := "Provider=MSDASQL.1;Persist Security Info=False;User ID=sa;Data Source=MyDatabase;SERVER=164.164.64.25;UID=sa;WSID=MANJU;DATABASE=ProductCenter;Address=164.164.64.25,1433"

Systemname - MANJU
DatabaseName - ProductCenter
Alias/Source - MyDatabase
Addressofthe remote machine-164.164.64.25
Port-1443
                   
                                Good luck
                                    Manju
                 
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
manjushanCommented:
Sure u can connect to a remote server using Ado typ lib.
User connection string will look like this

ConnectionString := "Provider=MSDASQL.1;Persist Security Info=False;User ID=sa;Data Source=MyDatabase;SERVER=164.164.64.25;UID=sa;WSID=MANJU;DATABASE=ProductCenter;Address=164.164.64.25,1433"

Systemname - MANJU
DatabaseName - ProductCenter
Alias/Source - MyDatabase
Addressofthe remote machine-164.164.64.25
Port-1443
                   
                                Good luck
                                    Manju
                 
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Delphi

From novice to tech pro — start learning today.