CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Nov 2010
    Posts
    54

    Use VC 2008 with SQL Server 2008?

    Hi,

    I want to write a VC 2008(MFC) app to create a SQL Server database, then create a data table inside it, and then add some records to the table. I am using SQL Server 2008. I want to know which method is the best? ADO, OLE-DB, ODBC, DAO, or any other methods? Which method is recommended by Microsoft?

    Thanks

  2. #2
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: Use VC 2008 with SQL Server 2008?

    I tried to use DAO to access SQL Server 2008 but without success.
    ADO works good. note that you should use SQLNCLI10 provider, not SQLOLEDB.

    And I'm sure OLE-DB and ODBC will work too.
    Victor Nijegorodov

  3. #3
    GCDEF is offline Elite Member Power Poster
    Join Date
    Nov 2003
    Location
    Florida
    Posts
    12,637

    Re: Use VC 2008 with SQL Server 2008?

    I use ODBC. It works the same as it always has.

  4. #4
    Join Date
    Mar 2010
    Location
    Melbourne Australia
    Posts
    454

    Re: Use VC 2008 with SQL Server 2008?

    you can also use the native driver

    http://msdn.microsoft.com/en-us/library/ms131291.aspx

    so there are no external dependencies

Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured