Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: static/dynamic/embedded SQL distinctions

Re: static/dynamic/embedded SQL distinctions

From: --CELKO-- <jcelko212_at_earthlink.net>
Date: 22 Aug 2005 13:00:28 -0700
Message-ID: <1124740828.913875.212350@z14g2000cwz.googlegroups.com>


Dynamic SQL is made up on the fly by a procedure or end user as a string contianing SQL statements. The ANSI Standards have PREPARE and EXECUTE statements for this. Microsoft and other vendors will do it differently, but it is the same idea. Like having Query Analyzer in your program -- and just as dangerous.

Embedded SQL is placed inside a host program, not built on the fly. Its statements begin with the keywords "EXEC SQL <sql code>" . A preprocessor converts these statements into API or CLI calls appropriate for the host language.

Static SQL is simply native SQL code. Since SQL has to exist in a host program to talk to the outside world, it will be embedded somewhere. Or it can be part of a trigger, stored procedure, etc.

You missed the SQL/CLI, ODBC, JDBC, etc. which are call level interfaces from host languages to an SQL database.

. Received on Mon Aug 22 2005 - 15:00:28 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US