Using CF.query positional argument syntax
Positional arguments support a subset of
code. The following is the syntax for the positional argument style:
// CF.query positional argument syntax
CF.query(datasource, sql);
CF.query(datasource, sql, maxrows);
CF.query(datasource, sql, username, password);
CF.query(datasource, sql, username, password, maxrows);
Note: When using positional arguments, do not use curly braces {}.
About the CF.query record set
The
function returns a RecordSet object, which is an instance of the RecordSet class of
CF.query
objects. The RecordSet class provides a wide range of functions for handling record set data.
You use methods in the RecordSet ActionScript class in your client-side ActionScript to change
data returned in the
Currently, the following methods are available in the RecordSet class:
:
Method
addItem
addItemAt
addView
filter
getColumnNames
getItemAt
getItemID
getLength
getNumberAvailable
isFullyPopulated
isLocal
removeAll
removeItemAt
replaceItemAt
setDeliveryMode
setField
sort
sortItemsBy
CF.query
record set.
CF.query
Description
Appends a record to the end of the specified RecordSet
Inserts a record at the specified index
Requests notification of changes in a RecordSet object's state
Creates a new RecordSet object that contains selected records from the
original RecordSet object
Returns the names of all the columns of the RecordSet
Retrieves a record from a RecordSet object
Gets the unique ID corresponding to a record
Returns the total number of records in a RecordSet object
Returns the number of records that have been downloaded from the server
Determines whether a RecordSet object can be edited or manipulated
Determines whether a RecordSet object is local or server-associated
Removes all records from the RecordSet object
Removes a specified record
Replaces the entire contents of a record
Changes the delivery mode of a server-associated record set
Replaces one field of a record with a new value
Sorts all records by a specified compare function
Sorts all the records by a selected field
arguments, and you can create more efficient
Using the CF.query function
659
Need help?
Do you have a question about the COLDFUSION MX 61-DEVELOPING COLDFUSION MX and is the answer not in the manual?
Questions and answers