Connect to database from C++?

Discussion in 'C++' started by Rune Allnor, Mar 22, 2011.

  1. Rune Allnor

    Rune Allnor Guest

    Hi all.

    I'd like to connect to a database, using an ODBC connection,
    from a C++ application.

    What options do I have, sticking with standard C++ as long
    as possible?

    I know how to do his through the Qt library, but that's
    unavailable at this particular system.

    Rune
     
    Rune Allnor, Mar 22, 2011
    #1
    1. Advertisements

  2. On 22 mar, 09:20, Rune Allnor <> wrote:
    > I'd like to connect to a database, using an ODBC connection,
    > from a C++ application.
    >
    > What options do I have, sticking with standard C++ as long
    > as possible?


    There is the SOCI project which is released under boost license and is
    rather standard C++/Boost friendly.
    But the ODBC backend is not officially maintained:
    http://soci.sourceforge.net/

    --
    Michael
     
    Michael Doubez, Mar 22, 2011
    #2
    1. Advertisements

  3. Rune Allnor

    Goran Guest

    On Mar 22, 9:20 am, Rune Allnor <> wrote:
    > Hi all.
    >
    > I'd like to connect to a database, using an ODBC connection,
    > from a C++ application.
    >
    > What options do I have, sticking with standard C++ as long
    > as possible?
    >
    > I know how to do his through the Qt library, but that's
    > unavailable at this particular system.


    iODBC, perhaps? (http://www.iodbc.org). But you'll still need database
    driver for your system and database.

    Goran.
     
    Goran, Mar 22, 2011
    #3
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Kate Perry

    connect to db2 database using dbi?

    Kate Perry, Jul 10, 2003, in forum: Perl
    Replies:
    0
    Views:
    3,517
    Kate Perry
    Jul 10, 2003
  2. SSP
    Replies:
    1
    Views:
    3,274
    Jeff Cochran
    Jul 1, 2003
  3. Daniel Bass

    ASP.NET database won't connect...

    Daniel Bass, Aug 6, 2003, in forum: ASP .Net
    Replies:
    5
    Views:
    591
    Benny Tordrup
    Aug 7, 2003
  4. vijay
    Replies:
    2
    Views:
    3,553
    vijaya kumar.P
    Aug 29, 2003
  5. Otis Mukinfus
    Replies:
    3
    Views:
    1,206
    Juan T. Llibre
    Jul 8, 2005
  6. Replies:
    3
    Views:
    42,134
    Roedy Green
    Nov 16, 2005
  7. Replies:
    2
    Views:
    587
  8. Mohsen Pahlevanzadeh

    Qt connect and first connect or unicode

    Mohsen Pahlevanzadeh, Sep 17, 2013, in forum: Python
    Replies:
    3
    Views:
    424
    Mohsen Pahlevanzadeh
    Sep 18, 2013
Loading...