About stored procedures – Adobe Dreamweaver CC 2015 User Manual
Page 671
664
Building applications visually
Last updated 6/3/2015
For more information on the type and size of SQL variables, se
.
6
Close the dialog box.
Dreamweaver inserts ASP code in your page that, when run on the server, creates a command that inserts, updates,
or deletes records in the database.
By default, the code sets the Prepared property of the Command object to true, which makes the application server
reuse a single compiled version of the object every time the command is run. To change this setting, switch to Code
view and change the Prepared property to false.
7
Create a page with an HTML form so users can enter record data. In the HTML form, include three text fields
(txtCity, txtAddress, and txtPhone) and a submit button. The form uses the GET method and submits the text field
values to the page that contains your command.
About stored procedures
Although you can use server behaviors to build pages that modify databases, you can also use database manipulation
objects such as stored procedures or ASP command objects to build the pages.
A stored procedure is a reusable database item that performs some operation on the database. A stored procedure
contains SQL code that can, among other things, insert, update, or delete records. Stored procedures can also alter the
structure of the database itself. For example, you can use a stored procedure to add a table column or even delete a table.
A stored procedure can also call another stored procedure, as well as accept input parameters and return multiple values
to the calling procedure in the form of output parameters.
A stored procedure is reusable in the sense that you can reuse a single compiled version of the procedure to execute a
database operation a number of times. If you know a database task will be executed more than a few times—or the same
task will be executed by different applications—using a stored procedure to execute that task can make database
operations more efficient.
Note: MySQL and Microsoft Access databases do not support stored procedures.
Type in database
Type in Dreamweaver
Size
Numeric (MS Access, MS SQL Server,
MySQL)
Double
-1
Boolean, Yes/No (MS Access, MS SQL
Server, MySQL)
Double
-1
Date/Time (MS Access, MS SQL Server,
MySQL)
DBTimeStamp
-1
All other types of text fields, including the
MySQL text data types char, varchar and
longtext
LongVarChar
check database table
Text (MS Access) or nvarchar, nchar (MS
SQL Server)
VarWChar
check database table
Memo (MS Access), ntext (MS SQL Server),
or fields that support large amounts of
text
LongVarWChar
1073741823