Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 C++ API

Author  Topic 

zutroy
Starting Member

4 Posts

Posted - 2008-05-23 : 20:22:15
Hi everyone,

Are there any SQL Server 2000 C++ libs out there (free)? I vaguely remember using ODBC in my database class in college, but that was some time ago. Or, if no libs exist, could someone point me to a good ODBC tutorial?

Thanks a bunch
Z

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2008-05-23 : 20:27:05
A quick google for "C++ ODBC Tutorial" gives this as the very first result:

http://www.dreamincode.net/forums/showtopic21309.htm

- Jeff
http://weblogs.sqlteam.com/JeffS
Go to Top of Page

zutroy
Starting Member

4 Posts

Posted - 2008-05-23 : 20:36:58
Thanks for the link,

I was hoping for a .dll that I could link to that had a nice api for sql server connections, transactions, queries, etc. I'd like to avoid ODBC if possible. I did find SQLAPI++ but it isn't free.

Thanks again,
Z
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2008-05-23 : 22:09:27
There's ADO:

http://www.codersource.net/mfc_ado_select.html

and OLEDB:

http://www.codeproject.com/KB/database/DBDevVCOLEDB.aspx

If you can use .NET, you can use C++ with ADO.NET:

http://www.codeproject.com/KB/mcpp/adodemo.aspx

That's all I have for now. Of course, you can also look into C# if that will work for you. If you know C++, C# will be the easiest thing in the world for you to learn and you'll never go back to C++.

- Jeff
http://weblogs.sqlteam.com/JeffS
Go to Top of Page

zutroy
Starting Member

4 Posts

Posted - 2008-05-25 : 05:13:28
C# is an option. I have never used it, but from what I hear it is not that different than C++. Does C# have a set of SQL Server libs? Quick search didn't find anything.

Thanks again,
Z
Go to Top of Page

zutroy
Starting Member

4 Posts

Posted - 2008-05-25 : 05:48:06
Nevermind. I found one.

This looks like it will work:
http://www.csharp-station.com/Tutorials/AdoDotNet/Lesson01.aspx

Thanks for all your help.
Z


Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2008-05-25 : 08:47:28
As you've probably found out by now, C# uses the .NET Framework which has tons of libraries ready to go for accessing sql server; see:

http://msdn.microsoft.com/en-us/library/system.data.sqlclient.aspx

C# is different from C++, closer to Java really, and it will take a little getting used to, but once you do I think you will really enjoy it.

- Jeff
http://weblogs.sqlteam.com/JeffS
Go to Top of Page
   

- Advertisement -