|
-
Jan 16th, 2002, 07:15 AM
#1
Thread Starter
Lively Member
Databases
I was wondering if anyone give me the code for simple databses. I want to be able to do is read a field in a certain row. I know some sql but I do not know how to use it in c++.
My database is called game.mdb, table ch1. I want to read the field Health where name = "Silas". for example. How would be able to get this information into a int variable?
Thanks for any help.
-
Jan 16th, 2002, 04:11 PM
#2
You need to decide what kind of database connection you want. MS supports mainly ADO now, you can find a lot of it in MSDN. Then there are ODBC, DAO, OLE DB etc. MFC has some wrapper classes around DAO, it's pretty easy to use. MySQL databases can be accessed through an API that you can download at their page.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jan 17th, 2002, 07:01 AM
#3
Thread Starter
Lively Member
Personally, I don't really care which type of database I use. All i want to be able to do is just basic accessing of the database. If some one could tell me a site to go to that has good tutorials or give me the code for just basic accessing of the database, that would be great.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|