Open Database Connectivity: Difference between revisions
Line 53: | Line 53: | ||
=== Microsoft and MDAC === |
=== Microsoft and MDAC === |
||
[[Microsoft]] released the first ODBC product as a set of [[Dynamic-link library|DLLs]] for [[Microsoft Windows]]. |
[[Microsoft]] released the first ODBC product as a set of [[Dynamic-link library|DLLs]] for [[Microsoft Windows]]. From 2006, Microsoft has shipped its own ODBC with every supported version of Windows: compare [[Microsoft Data Access Components]]. Microsoft even includes ODBC drivers that provide limited database-like query facilities for [[Microsoft Excel|Excel]] spreadsheets and [[Comma-separated values|comma-separated]] text files. |
||
The <code>ODBCConf</code> utility provides a command-line interface to Microsoft ODBC configuration.<ref>{{ cite book | last = Mueller | first = John Paul | title = Windows Administration at the Command Line for Windows Vista, Windows 2003, Windows XP, and Windows 2000 | url = http://books.google.com/books?id=Ua819DVKQPwC | accessdate = 2010-11-29 | edition = 11 | series = In the field results | year = 2007 | publisher = John Wiley and Sons | location = Indianapolis, Indiana | isbn = 9780470046166 | page = 70 | pages = 622 | quote = The ODBCConf utility helps you configure ODBC at the command line, rather than using the ODBC Data Source Administrator utility available in the Administrative Tools folder of the Control Panel - listed as the Data Sources (ODBC) console. You can use this utility to configure new data sources, check data source status, and perform other tasks on a remote machine from the command line. }}</ref> |
The <code>ODBCConf</code> utility provides a command-line interface to Microsoft ODBC configuration.<ref>{{ cite book | last = Mueller | first = John Paul | title = Windows Administration at the Command Line for Windows Vista, Windows 2003, Windows XP, and Windows 2000 | url = http://books.google.com/books?id=Ua819DVKQPwC | accessdate = 2010-11-29 | edition = 11 | series = In the field results | year = 2007 | publisher = John Wiley and Sons | location = Indianapolis, Indiana | isbn = 9780470046166 | page = 70 | pages = 622 | quote = The ODBCConf utility helps you configure ODBC at the command line, rather than using the ODBC Data Source Administrator utility available in the Administrative Tools folder of the Control Panel - listed as the Data Sources (ODBC) console. You can use this utility to configure new data sources, check data source status, and perform other tasks on a remote machine from the command line. }}</ref> |
Revision as of 15:37, 6 September 2011
This article needs additional citations for verification. (August 2009) |
In computing, ODBC (Open Database Connectivity) is a standard software interface for accessing database management systems (DBMS). The designers of ODBC aimed to make it independent of programming languages, database systems, and operating systems. Thus, any application can use ODBC to query data from a database, regardless of the platform it is on or DBMS it uses.
ODBC accomplishes platform and language independence by using an ODBC driver as a translation layer between the application and the DBMS. The application thus only needs to know ODBC syntax, and the driver can then pass the query to the DBMS in its native format, returning the data in a format the application can understand .
Overview
ODBC provides a standard software API method for accessing both relational and non-relational DBMS. It was developed by the SQL Access Group in 1992 in order to facilitate easier communication between applications and databases across computing platforms. Prior to its creation, if an application needed the ability to communicate with more than a single database, it would have to support and maintain an interface for each. ODBC provides a universal middleware layer between the application and DBMS, allowing the application developers to only have to learn a single interface, nor do they have to update their software if changes are made to the DBMS specification, only the driver needs updating. An ODBC driver can thus be thought of as analogous to a printer or other driver, providing a standard set of calls for the application to use, which then translates those commands into the correct commands at the DBMS end.
An application that can communicate through ODBC is referred to as ODBC-compliant. Any ODBC-compliant application can access any DBMS that has a corresponding driver. For the driver, the ODBC model allows for two different solutions, either having the driver reside on the client machine, or as part of a server-side solution. Drivers exist for all major DBMS, as well as nontraditional data models, such as flat text or CSV files.
Regardless of where the driver exists, the basic model is the same. The application sends ODBC commands to the driver, which then translates those commands into the native format of the DBMS. Once the DBMS has performed the query, it then sends those results back through the ODBC driver, which then translates them back into a standard format.
History
ODBC uses as its basis the various Call Level Interface (CLI) specifications from the SQL Access Group, X/Open (after 1996 part of The Open Group), and the ISO/IEC. Microsoft, in partnership with Simba Technologies, created ODBC by adapting the SQL Access Group CLI.[1] It released ODBC 1.0 in September 1992.[2] After ODBC 2.0, Microsoft decided to align ODBC 3.0 with the CLI specification making its way through X/Open and ISO. In 1995, SQL/CLI became part of the international SQL standard.[3]
Version history:[4]
- 1.0: released in September 1992[5]
- 2.0: ca 1994
- 2.5
- 3.0: ca 1995
- 3.5: ca 1997
- 3.8: ca 2009, with Windows 7[6]
Drivers
An ODBC driver enables an ODBC consumer to interact with a data source. ODBC drivers are analogous to ADO.NET data providers, JDBC drivers, and OLE DB providers.
ODBC drivers can be created to access such simple data stores as a text file or spreadsheet, through to such complex databases as Oracle, Microsoft SQL Server, Sybase ASE, and many others. It can also provide access to hierarchical data stores such as email systems.
However, because different data store technologies can have different capabilities, every ODBC driver cannot implement every possible interface available in the ODBC standard. Microsoft describes the availability of an interface as "driver-specific", as it may not be applicable depending on the data store technology involved. Note also that providers may augment the capabilities of a data store.
Implementations
ODBC implementations run on many operating systems, including Microsoft Windows, Unix, Linux, OS/2, OS/400, IBM i5/OS, and Mac OS X. Hundreds of ODBC drivers exist, including drivers for enterprise DBMS such as Oracle, DB2, Microsoft SQL Server, Sybase, Pervasive SQL, IBM Lotus Domino, MySQL, PostgreSQL, OpenLink Virtuoso, and desktop database products such as FileMaker and Microsoft Access.
iODBC
iODBC (Independent Open DataBase Connectivity) offers an open source, platform-independent implementation of both the ODBC and X/Open specifications, generally used on platforms other than Microsoft Windows. OpenLink Software maintains and supports the iODBC project and distributes its software under the LGPL and/or BSD License. Apple chose to bundle iODBC into Mac OS X and Darwin, starting with Darwin 6.0 and Mac OS X v10.2. Programmers have ported iODBC to several other operating systems and hardware platforms, including Mac OS 9, Linux (x86, x86-64, IA-64, Alpha, MIPS, and ARM), Solaris (SPARC and x86), AIX, HP-UX (PA-RISC and Itanium), Compaq Tru64, Digital UNIX, Dynix, Generic UNIX 5.4, FreeBSD, DG-UX, OpenVMS and AmigaOS.
IBM i5/OS
In the IBM i5/OS (formerly OS/400), IBM's DB2 implementation supports ODBC. The vendor provides ODBC Drivers for Windows and JDBC as part of the Server and Client Packages.
IBM also has a product called DB2 Connect which is used to provide ODBC functionality to Z/OS and Universal Database DB2 Environments.
Microsoft and MDAC
Microsoft released the first ODBC product as a set of DLLs for Microsoft Windows. From 2006, Microsoft has shipped its own ODBC with every supported version of Windows: compare Microsoft Data Access Components. Microsoft even includes ODBC drivers that provide limited database-like query facilities for Excel spreadsheets and comma-separated text files.
The ODBCConf
utility provides a command-line interface to Microsoft ODBC configuration.[7]
UnixODBC
The unixODBC project—headed, maintained and supported by Easysoft Director Nick Gorham—has become[update] the most common driver-manager for non-Microsoft Windows platforms (and for one Microsoft platform, Interix). It offered full ODBC3 support and Unicode in advance of its competitors. Most Linux distributions as of 2006[update] ship it, including Red Hat, Mandriva and Gentoo. Several vendors of commercial databases, including IBM (DB2, Informix), Oracle, and SAP (Ingres), use it for their own drivers. It includes GUI support for both KDE and GNOME. Many open source projects such as OpenOffice.org and Glade also make use of it. UnixODBC builds on any platform that supports the GNU autoconf tools, which is standard in most platforms. For licensing, UnixODBC uses the LGPL and the GPL.
UDBC
UDBC, a cross-platform fusion of ODBC and the SAG CLI, enabled non-Windows-based DBMS-independent application development at a time when shared-library implementations on Unix occurred only sporadically. This effort laid the foundation for the iODBC open source project.
Bridging configurations
JDBC-ODBC bridges
A JDBC-ODBC bridge consists of a JDBC driver which employs an ODBC driver to connect to a target database. This driver translates JDBC method calls into ODBC function calls. Programmers usually use such a bridge when a particular database lacks a JDBC driver. Sun Microsystems included one such bridge in the JVM, but viewed it as a stop-gap measure while few JDBC drivers existed. Sun never intended its bridge for production environments, and generally recommends against its use. As of 2008[update] independent data-access vendors deliver JDBC-ODBC bridges which support current standards for both mechanisms, and which far outperform the JVM built-in.[citation needed]
ODBC-JDBC bridges
An ODBC-JDBC bridge consists of an ODBC driver which uses the services of a JDBC driver to connect to a database. This driver translates ODBC function-calls into JDBC method-calls. Programmers usually use such a bridge when they lack an ODBC driver for a particular database but have access to a JDBC driver.
OLE DB
Microsoft provides an OLE DB-ODBC bridge for simplifying development in COM aware languages (i.e. Visual Basic). This bridge forms part of the MDAC system component bundle, together with other database drivers.
See also
References
- ^ Harindranath, G (2001). New perspectives on information systems development: theory, methods, and practice. Springer. p. 451. ISBN 9780306472510. Retrieved 2010-07-28.
The first ODBC drivers [...] used the SIMBA query processor, which translated calls into the Microsoft Jet ISAM calls, and dispatched the calls to the appropriate ISAM driver to access the backend [...]
{{cite book}}
: More than one of|pages=
and|page=
specified (help); Unknown parameter|coauthors=
ignored (|author=
suggested) (help) - ^ "Linux/UNIX ODBC - What is ODBC?".
- ^ ISO/IEC 9075-3 -- Information technology -- Database languages -- SQL -- Part 3: Call-Level Interface (SQL/CLI)
- ^ "ODBC Versions". Linux/UNIX ODBC. Easysoft. Retrieved 2009-10-27.
{{cite web}}
: Cite has empty unknown parameter:|month=
(help) - ^ Antal, Tiberiu Alexandru. "Access to an Oracle database using JDBC" (PDF). Cluj-Napoca: Technical University of Cluj-Napoca. p. 2. Retrieved 2009-10-27.
ODBC 1.0 was released in September 1992
- ^ "What's New in ODBC 3.8". Microsoft. Retrieved 2010-01-13.
Windows 7 includes an updated version of ODBC, ODBC 3.8.
- ^ Mueller, John Paul (2007). Windows Administration at the Command Line for Windows Vista, Windows 2003, Windows XP, and Windows 2000. In the field results (11 ed.). Indianapolis, Indiana: John Wiley and Sons. p. 70. ISBN 9780470046166. Retrieved 2010-11-29.
The ODBCConf utility helps you configure ODBC at the command line, rather than using the ODBC Data Source Administrator utility available in the Administrative Tools folder of the Control Panel - listed as the Data Sources (ODBC) console. You can use this utility to configure new data sources, check data source status, and perform other tasks on a remote machine from the command line.
{{cite book}}
: More than one of|pages=
and|page=
specified (help)