Specifications

311
CHAPTER 27
The Database API
Functions in the Database API let you manage database connections and access information that
is stored in databases.
In managing database connections, you can get the user name and password that are needed to
make a connection to a database, open up a database connection dialog box, and so on.
In accessing database information, you can, for example, fetch metadata that describes the schema
or structure of a database. This metadata includes information such as the names of tables,
columns, stored procedures, and views. You can also show the results of executing a database
query or stored procedure. When accessing a database through this API, you use structured query
language (SQL) statements.
Database API functions are used at design time when users are building web applications, as
opposed to runtime, when the web application is deployed.
You can use these functions in any extension. In fact, the Macromedia Dreamweaver MX
Server Behavior, Data Format, and Data Sources API functions all use these database functions.
The following example shows how the server behavior function,
getDynamicBindings(), is
defined for Recordset. (For all Dreamweaver versions other than MX, the file Recordset.js is
located in the Configuration/ServerBehaviors folder; for Dreamweaver MX, this JavaScript file is
located in the Configuration/ServerBehaviors/Shared folder.)