Embedded SQL

SQL statements embedded in a C or C++ source file are referred to as embedded SQL. A preprocessor translates these statements into calls to a runtime library. Embedded SQL is an ISO/ANSI and IBM standard.

Embedded SQL is portable to other databases and other environments, and is functionally equivalent in all operating environments. It is a comprehensive, low-level interface that provides all the functionality available in the product. Embedded SQL requires knowledge of C or C++ programming languages.

Embedded SQL applications

You can develop C or C++ applications that access the SAP Sybase IQ server using the SAP Sybase IQ embedded SQL interface. The command line database tools are examples of applications developed in this manner.


 Applications connecting to SAP Sybase IQ using embedded SQL.

Embedded SQL is a database programming interface for the C and C++ programming languages. It consists of SQL statements intermixed with (embedded in) C or C++ source code. These SQL statements are translated by a into C or C++ source code, which you then compile.

At runtime, embedded SQL applications use an SAP Sybase IQ interface library called DBLIB to communicate with a database server. DBLIB is a dynamic link library (DLL) or shared object on most platforms.

SAP Sybase IQ provides two flavors of embedded SQL. Static embedded SQL is simpler to use, but is less flexible than dynamic embedded SQL.