Adobe 38040334 - Dreamweaver CS3 User Manual page 563

Pc
Hide thumbs Also See for 38040334 - Dreamweaver CS3:
Table of Contents

Advertisement

Click OK to add the recordset to the Bindings panel.
4
Example: Selecting specific rows from a table and ordering the results
The following example selects two rows from the Employees table, and selects the job type using a variable that you
must define. The results are then ordered by employee name.
SELECT emplNo, emplName
FROM Employees
WHERE emplJob = 'varJob'
ORDER BY emplName
Expand the Tables branch to display all of the tables in the selected database; then expand the
1
display the individual table rows.
Build the SQL statement as follows:
2
Select
, and click the Select button.
emplNo
Select
, and click the Select button.
emplName
Select
and click the Where button.
emplJob,
Select
, and click the Order By button.
emplName
Place the insertion point after
3
Define the variable
4
'varJob'
values in the Name, Default Value, and Run-Time Value columns:
5
Click OK to add the recordset to the Bindings panel.
Define URL parameters
URL parameters store retrieved information input by users. Before you begin, make sure you pass a form or URL
parameter to the server. After you define the URL variable, you can use its value in the currently selected page.
In the Document window, open the page that will use the variable.
1
2
Select Windows > Bindings to display the Bindings panel.
In the Bindings panel, click the Plus (+) button and select one of the following from the pop-up menu:
3
Document Types
Menu item in Bindings panel for URL variable
ASP
Request Variable > Request.QueryString
ColdFusion
URL Variable
JSP
Request Variable
PHP
URL Variable
4
In the URL Variable dialog box, enter the name of the URL variable in the box, and click OK.
The URL variable name is normally the name of the HTML form field or object used to obtain its value.
The URL variable appears in the Bindings panel.
5
in the SQL text area and type
WHERE emplJob
by clicking the Plus (+) button in the Variables area and entering the following
September 4, 2007
Employees
(include the equal sign).
='varJob'
,
,
varJob
CLERK
Request("job")
DREAMWEAVER CS3
556
User Guide
table to
.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dreamweaver cs3

Table of Contents