Overview of Building SQL Server Applications

A database application uses an Application Programming Interface (API) to send commands to a database:

Commands sent to Microsoft® SQL Server™ through the database API must comply with the Transact-SQL language. Transact-SQL complies with the Entry Level of the SQL-92 standard, but also supports many more features of SQL-92. It also supports some powerful extensions to the SQL-92 standard. The SQL Server OLE DB provider and SQL Server ODBC driver also support the ODBC SQL specification. For more information about Transact-SQL, see Getting Started with Transact-SQL.

SQL Server supports a number of APIs for building general purpose database applications.

Topic Description
ADO and SQL Server

(Microsoft ActiveX® Data Objects)

COM API recommended as the primary API for accessing data from general business applications, such as human resources, accounting, and marketing applications. ADO encapsulates the OLE DB API in a simplified object model that reduces application development and maintenance costs. The SQL Server OLE DB provider is the preferred provider to use in ADO applications that access SQL Server. ADO, like OLE DB, can access data from many sources, not just SQL databases.
OLE DB and SQL Server Microsoft's strategic, low-level, COM API for accessing data. OLE DB is recommended for developing tools, utilities, or low-level components that need high performance. The SQL Server OLE DB provider is a native, high performance provider that directly accesses the SQL Server TDS protocol.
ODBC and SQL Server

(Open Database Connectivity)

Open C API designed to access data in SQL databases. The SQL Server ODBC driver is a native, high-performance driver that directly accesses the SQL Server TDS protocol.
Embedded SQL for C and SQL Server Standard API defined for accessing SQL databases from C or COBOL applications.
DB-Library for C Legacy C API designed to work with SQL Server.

SQL Server also supports a number of interfaces that let applications make full use of all SQL Server features.

Topic Description
SQL-DMO

(SQL Distributed Management Objects)

Set of COM interfaces for managing and administering SQL Server.
Replication Programming Set of COM interfaces for defining and managing replication between SQL Server databases. You can also replicate data from heterogeneous third-party databases to SQL Server.
DTS Programming

(Data Transformation Services)

Set of COM interfaces (based on OLE DB) for defining and executing complex data transformations between OLE DB data providers.
Open Data Services Programming C API for writing SQL Server Extended Stored Procedures.
Microsoft Distributed Transaction Coordinator Allows applications to define distributed transactions that protect the integrity of a series of updates made against multiple servers.

Additional considerations regarding the use of all these APIs are discussed in Application Development Architecture.

Through its support of ODBC, SQL Server also supports applications written to the Remote Data Objects (RDO) and Data Access Objects (DAO) APIs. These are object APIs that encapsulate ODBC. They are not discussed further in the SQL Server Books Online. Programmers using RDO and DAO should refer to ODBC and SQL Server for implementation details for the SQL Server ODBC Driver.

The SQL Server Books Online topics on ADO, OLE DB, and ODBC do not cover the full functionality of those APIs. These topics only cover the issues specific to those APIs when you are using the SQL Server OLE DB provider or the SQL Server ODBC driver. They assume that you are familiar with the general concepts for the API you are using, and that you have access to the documentation for the API. You can download the documentation for ADO, OLE DB, and ODBC from the Web site http://www.microsoft.com/data. The Programmer's References for both OLE DB and ODBC are available from Microsoft Press.

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.