Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Mar 2004
    Location
    Durham, UK
    Posts
    62
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Exclamation Accessing databases on the net from a c++ app (URGENT!!)

    I'm already accessing my MSAccess DB using asp.net/ado.net with the oledb classes and methods, but I'd like to do something similar from a C++ app written on my PC. I'm a little bewildered though:[list=1][*]ADO, OLE, ODBC... it seems these can all be used for my db, what's the difference?[*]Presuming I was to use oledb or odbc, where do I start (I don't have VS.net only 6.0)?[*]What's the process for connecting & performing queries on a remote (or local) db? Akin to the way it's done from a web-page?[*]Where can I find good tutorials (my c++ & sql is excellent just not how it all links together!)?[/list=1]

    [edit]
    Just to clarify, I'm not currently using mfc if possible. I want the process to be:
    1)Create a connection to the database (preferably on the net but a local location would suffice - NOT setting up the project for a specific DB)
    2)Create a command to get information from the db
    3)Execute the command and get hold of the data
    4)Go through the data
    5)Close the connections.

    All the examples I've seen have you building a VS project about some particular database wheras I want to be able to select a database from somewhere and do stuff to it. There must be standard classes around to do this like how you do in asp; I'm not after writing a load of code to do that. In asp.net you just create a connection, command object etc then pass the command to the connection and get a set of data back - that's what I'm after here.

    Thankyou.
    Last edited by d000hg; 03-26-2004 at 12:59 PM.

  • #2
    Senior Coder
    Join Date
    Feb 2004
    Posts
    1,206
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I just quickly entered a search on Google, and came up with these links:
    http://www.experts-exchange.com/Prog..._20918430.html
    http://publib.boulder.ibm.com/infoce...ADME_Linux.htm
    http://www.hotscripts.com/Detailed/11714.html
    http://www.devarticles.com/c/a/MySQL...mote-Database/

    It looks to me as if it depends on what database you're going to use, and you should get the appropriate API for it.

    I've never done anything like this using C++, so I apologise, I cannot be of more assistance.

    Good luck,
    Sadiq.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •