Content deleted Content added
Cleanup and ad removal |
|||
Line 1:
'''Embedded SQL''' is a method of combining the [[computing]] power of a [[programming language]] and the [[database]] [[Data Manipulation Language|manipulation]] capabilities of [[SQL]]. Embedded SQL [[statement (programming)|statements]] are SQL statements written inline with the program [[source code]] of the host language. The embedded SQL statements are [[parsing|parsed]] by an embedded SQL [[preprocessor]] and replaced by host-language [[call site|calls]] to a code [[library (computing)|library]]. The output from the preprocessor is then compiled by the host [[compiler]]. This allows programmers to embed SQL statements in programs written in any number of languages such as [[:Category:C programming language family|C/C++]], [[COBOL]] and [[Fortran]]. This differs from SQL-derived programming languages that don't go through discrete preprocessors, such as [[PL/SQL]] and [[Transact-SQL|T-SQL]].
The SQL standards committee defined the embedded SQL standard in two steps: a formalism called '''Module Language''' was defined, then the embedded SQL standard was derived from Module Language.<ref name="modulelang">
Line 8:
|publisher=[[Oracle Corporation]]
|accessdate=2008-07-14}}
</ref> The SQL standard defines embedding of SQL as ''embedded SQL'' and the language in which SQL queries are embedded is referred to as the ''host language''. A popular host language is C.
== Systems that support
; C/C++▼
: APRE is an embedded SQL precompiler provided by [[Altibase]] Corp. for its DBMS server.▼
=== IBM DB2 ===
Line 21 ⟶ 25:
}}</ref>
===
; C/C++
SAP Sybase ASE 15.7 supports Embedded SQL for C and COBOL as part of the Software Developer Kit [[Sybase]].<ref>{{cite web▼
: Embedded SQL for C has been deprecated as of [[Microsoft SQL Server]] 2008 although earlier versions of the product support it.<ref>{{cite web▼
|url=http://www.sybase.com/products/allproductsa-z/softwaredeveloperkit/embeddedsql|title=EmbeddedSQL▼
|url=http://msdn.microsoft.com/en-us/library/ms143729.aspx▼
|work=SAP Sybase Products▼
|title=Deprecated Database Engine Features in SQL Server 2008▼
|publisher=SAP Sybase▼
|work=SQL Server 2008 Books Online (March 2009)▼
|accessdate=2012-09-05▼
|publisher=[[Microsoft]]▼
|accessdate=2009-04-10▼
}}</ref>
SAP Sybase SQL Anywhere supports Embedded SQL for C and C++ as part of the SQL Anywhere database management system [[SQL Anywhere]].<ref>{{cite web▼
; [[Ada (programming language)|Ada]]
|url=http://www54.sap.com/pc/tech/database/software/sybase-sql-anywhere/index.html|title=SAP Sybase SQL Anywhere▼
|work=SAP Sybase Products▼
|publisher=SAP Sybase▼
|accessdate=2013-05-02▼
}}</ref>▼
SAP Sybase IQ supports Embedded SQL for C and C++ as part of the Sybase IQ database management system [[Sybase IQ]].<ref>{{cite web▼
|url=http://www54.sap.com/pc/tech/database/software/sybase-iq-big-data-management/index.html|title=SAP Sybase IQ▼
|work=SAP Sybase Products▼
|publisher=SAP Sybase▼
|accessdate=2013-05-02▼
}}</ref>▼
▲=== Oracle Corporation ===
▲; Ada : Pro*Ada was officially desupported by [[Oracle Corporation|Oracle]] in version 7.3. Starting with Oracle8, Pro*Ada has been replaced by SQL*Module but appears to have not been updated since.<ref>{{cite web
|url=http://download.oracle.com/docs/cd/B10501_01/server.920/a96530/migcompa.htm#1010868
|title=Ada Support in Version 8
Line 51 ⟶ 44:
|accessdate=2008-07-14
}}</ref> SQL*Module is a module language that offers a different programming method from embedded SQL. SQL*Module supports the Ada83 language standard for Ada.
; C/C++ : [[Pro*C]] became Pro*C/C++ with Oracle8. Pro*C/C++ is currently supported as of Oracle Database 11''g''.▼
; C/C++
; COBOL : Pro*COBOL is currently supported as of Oracle Database 11''g''.▼
▲
; Fortran : Pro*FORTRAN is no longer updated as of Oracle8 but Oracle will continue to issue patch releases as bugs are reported and corrected.<ref name="langalts"/>▼
; Pascal : Pro*Pascal was not released with Oracle8.<ref name="langalts"/>▼
; COBOL▼
; PL/I : Pro*PL/I was not released with Oracle8. The ''Pro*PL/I Supplement to the Oracle Precompilers Guide'', however, continued to make appearances in the Oracle Documentation Library until release 11''g''. As of release 12c, the Pro*PL/I has been removed from the Oracle Documentation Library.<ref name="langalts">{{cite web▼
; Fortran
▲
; [[Pascal (programming language)|Pascal]]
; [[PL/I]]
▲
|url=http://download.oracle.com/docs/cd/A64702_01/doc/server.805/a58232/ch01.htm#505
|title=Language Alternatives
Line 69 ⟶ 72:
: [http://www.cobol-it.com Cobol-IT] is now distributing a COBOL precompiler for PostgreSQL
===
▲SAP Sybase ASE 15.7 supports
▲; C/C++
▲|url=http://www.sybase.com/products/allproductsa-z/softwaredeveloperkit/embeddedsql|title=EmbeddedSQL
▲: APRE is an embedded SQL precompiler provided by [[Altibase]] Corp. for its DBMS server.
▲|work=SAP Sybase Products
▲|publisher=SAP Sybase
▲|accessdate=2012-09-05
▲}}</ref>
▲; COBOL
▲=== MySQL ===
▲SAP Sybase SQL Anywhere supports
▲|url=http://www54.sap.com/pc/tech/database/software/sybase-sql-anywhere/index.html|title=SAP Sybase SQL Anywhere
▲Embedded SQL for C has been deprecated as of [[Microsoft SQL Server]] 2008 although earlier versions of the product support it.<ref>{{cite web
▲|work=SAP Sybase Products
▲|url=http://msdn.microsoft.com/en-us/library/ms143729.aspx
▲|publisher=SAP Sybase
▲|title=Deprecated Database Engine Features in SQL Server 2008
▲|accessdate=2013-05-02
▲|work=SQL Server 2008 Books Online (March 2009)
▲|publisher=[[Microsoft]]
▲|accessdate=2009-04-10
}}</ref>
▲SAP Sybase IQ supports
▲|url=http://www54.sap.com/pc/tech/database/software/sybase-iq-big-data-management/index.html|title=SAP Sybase IQ
▲|work=SAP Sybase Products
▲|publisher=SAP Sybase
▲|accessdate=2013-05-02
▲}}</ref>
== Embedded SQL through ___domain-specific languages ==
Line 105 ⟶ 101:
== See also ==
* [[Language binding]]
* [[PL/SQL]]
* [[Pro*C/C++]]
* [[SQL/OLB]]
* [[SQL PL]]
* [[Transact-SQL]]
== References ==
|