Setting Up the Student Registration Data Source

Before you start the Enroll tutorial, you need to set up the Student Registration database and register it as an ODBC data source. Choose a database format for which you have the corresponding database management system (DBMS) and 32-bit ODBC driver. Microsoft ships with Visual C++ the 32-bit ODBC drivers for most standard database formats, including: SQL Server, Access, Paradox, dBase, FoxPro, Excel, and Oracle.

  • If you want to use MFC database support for SQL Server, you need the SQL Server product in addition to the ODBC driver for SQL Server that is provided with Visual C++.

  • If you want to use other database formats, you need the DBMS as well as the ODBC driver. See Installing Additional 32-bit ODBC Drivers for Your DBMS, later in this lesson, for more information.

  • If you want to use the Microsoft Access database format, you need only the 32-bit Microsoft Access ODBC driver to create a database schema. This driver is installed automatically when you run a Typical setup. This is an exception to the requirements listed above. You may find it helpful, however, to use Microsoft Access itself in conjunction with MFC database support, as it will facilitate working interactively with your database schema and data.

Suggested Reading

  • , Visual C++ Samples

  • , Visual C++ Programmer’s Guide

  • , Visual C++ Programmer’s Guide

To set up the student registration database, you must:

If you are using a DBMS other than the prebuilt Microsoft Access StdReg32.mdb database file, you need to add tables to your database so that it matches the Student Registration database schema. Additionally, you may need to install drivers other than those that Visual C++ Setup installs for you. In this case, perform the following procedure(s):

Each of these procedures is described in the following topics.