Link to home
Start Free TrialLog in
Avatar of FaithNoMore
FaithNoMore

asked on

Connecting to a Sql Server Database (remotely) Using C++ (compiler DevC++)

I am basically looking for a reference or a api that makes connecting to Sql Server 2000 nice and easy, can anyone help me out. (Using a Windows XP machine).


A link to some sample code, or posting some sample code on making a connection, then a simple query would be nice.  Would I have to use ADO?

-- FNM
ASKER CERTIFIED SOLUTION
Avatar of lakshman_ce
lakshman_ce

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of FaithNoMore
FaithNoMore

ASKER

I am not using Visual C++, so using the #import directive doesnt work, which basically means most msdn and most articles I have found have been useless until I can figure out how to load ADO into my DevC++ project.  This is my main problem  :)
What language/compiler are you using?

With Borland there's a utility that creates a .lib file from a DLL which gives you the basic functionality of the #import command.

But, that probably won't be enough if you're trying to do COM programming.

Try looking for ODBC support for you compiler, that's simple and most vendors have implemented something.  The ODBC drivers are also easily available.  There's even an open-source library called "free-tds" if you're using gcc.

DJ