Syntax
cmdSelect.setColumns(columns)
Arguments |
Description |
columns |
Sets the columns
for the cmdSelect
object and query, overwriting any prior setting. |
|
Returns
Return value is undefined.
Description
The cmdSelect.setColumns() method
specifies the columns, i.e., fields, to be retrieved
by the cmdSelect.execute()
method. The columns
argument may be a comma-delimited string, an array, or
an array literal specifying the field names of a given
table.
Example
The following setColumns() example
uses a comma-delimited string to set the columns to be
retrieved. It then prints out the columns specified by the setColumns() method.
var sel = new cmdSelect("AddressBook");
sel.setColumns("FirstName, LastName, Email");
response.write(sel.getColumns());
Output:
FirstName, LastName, Email
Related
Topics
cmdSelect Object,
cmdSelect.getColumns(),
cmdSelect.execute()
|