Solved

Accessing db from C

Posted on 2000-04-22
1
203 Views
Last Modified: 2010-04-15
Can somebody please point me in the right direction. What I want to know is how to connect to a db, an MS Access for example. And ofcourse how to query the db. I'm using plain C.
0
Comment
Question by:sa9813
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 1

Accepted Solution

by:
syscyk earned 100 total points
ID: 2743446
You have a couple of options here, sa9813.
  You can use ODBC (Open DataBase Connect) to get to the database,  you can use embedded SQL (if your database supports it), or you can use the proprietary API that the database vendor gives you.  With Oracle, for instance, you get Pro C, or the ORACLE OCI.  The benefit of ODBC is that it is portable between databases. The downside is that it is slow, and only the most basic SQL stuff is supported.  I would suggest using the API supplied by the database vendor, that is ususally the best in terms of performance.  And when you are using a relational database, you need all the performance you can get, and then some.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
This is a short and sweet, but (hopefully) to the point article. There seems to be some fundamental misunderstanding about the function prototype for the "main" function in C and C++, more specifically what type this function should return. I see so…
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use nested-loops in the C programming language.
The goal of this video is to provide viewers with basic examples to understand and use switch statements in the C programming language.

687 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question