Jump to content

Databases and C++

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
5 replies to this topic

#1
Emir

Emir

    Newbie

  • Members
  • Pip
  • 5 posts
Hello everyone,

How does one use databases with C++ programs? I have some experience with writing C++ programs, as well as creating/using databases, but I'm not sure how to combine the two.

I'm suppose to make a simple GUI application [most probably using managed C++, Visual Studio] which stores and uses data from my database and help is needed :)

Thanks in advanced!
Emir

#2
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
It will depend entirely on the database API and/or whether you are connecting directly or using ADO. Your GUI can make a difference as well.

The first question would be: what type of database will you connect to?
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#3
Emir

Emir

    Newbie

  • Members
  • Pip
  • 5 posts
Thanks for the quick answer, WingedPanther!

Forgot to mention that :o I was intending to use a relational database [MySQL/Oracle].

#4
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
MySQL and Oracle are fairly different. Here's some links that may be useful:
MySQL :: MySQL 5.0 Reference Manual :: 20.12 MySQL C++ API
Oracle Database Online Documentation 10g Release 2 (10.2)

There are also various generic APIs available:
SQLAPI++ - C++ library for accessing SQL databases
SourceForge.net: Simple C++ Database API: Simple C++ Database API
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#5
killcode

killcode

    Learning Programmer

  • Members
  • PipPipPip
  • 96 posts
mysql++ maybe?
Posted Image

#6
killcode

killcode

    Learning Programmer

  • Members
  • PipPipPip
  • 96 posts
Lol wingedpanther, i was just about to post after Emir but didin't show that you posted after, i guess we posted at same time?

Ah nvm, my post useless now :P
Posted Image