Retrieving the record to delete (ASP and JSP)

Retrieving the record to delete (ASP and JSP)

After the results page passes a URL parameter to the delete page identifying the record to delete (see Identifying the record to delete (ASP and JSP)), the delete page must read the parameter, retrieve the record from the database table, and temporarily store the record in a recordset.

To retrieve the record to delete:

  1. In the Bindings panel (Window > Bindings), click the Plus (+) button and select Recordset.

    If the advanced dialog box appears, click the Simple button to open the simple dialog box.

  2. Name the recordset and specify where the data you want to delete is located using the Connection and Table pop-up menus.
  3. In the Columns area, select the All option to select all the columns in the database table.
  4. Configure the Filter area so that the value of your key column equals the value of the corresponding URL parameter passed by the results page.

    This kind of filter creates a recordset that contains only the record specified by the results page. For example, if your key column contains record ID information and is called PRID, and if the results page passes the corresponding record ID information in the URL parameter called id, then here’s how your Filter area should look:

    This is a picture of the feature being described.

  5. Click OK.

When the user selects a record on the results page, the delete page generates a recordset containing only the selected record.

The next step in building a page to delete records is to display the record to be deleted. See Displaying the data to be deleted (ASP and JSP).

Getting Started with Dreamweaver
Dreamweaver Basics
Working with Dreamweaver Sites
Laying Out Pages
Adding Content to Pages
Working with Page Code
Preparing to Build Dynamic Sites
Making Pages Dynamic
Developing Applications Rapidly
Building ColdFusion Applications Rapidly
Building ASP.NET Applications Rapidly
Building ASP and JSP Applications Rapidly