Maptitude GISDK Help |
Returns a list of fields that support aggregation rules.
aggr = FieldsSupportAggregations(string view, array fields, array options)
Argument |
Contents |
view |
The name of the view |
fields |
A list of fields to be considered |
No options are currently supported.
An array of fields that allow their aggregation modes to be set.
The array of fields can be null, if all fields are to be considered.
If the input fields array is not null, the return array is a sub-array of the input, i.e., it uses the same order and field specification as the input.
// Change the aggregation settings for the Population field.
table = GetTableStructure("State") // Get all the settings of the table
aggr = FieldsSupportAggregations("State", {"White", "Black", "Population"}, )
if ArrayPosition(aggr, {"Population"}, ) <> 0 then do
// We can set aggregation rules for "Population"
for i = 1 to table.length do
if table[i][1] = "Population" then
// Set the new aggregation rules:
table[i][7] = {{"Sum"},{"Count"}, {"Max"}}
// For ModifyTable: add the original field name
table[i] = table[i] + {table[i][1]}
end
ModifyTable("State", table)
end
else
ShowMessage("Cannot set aggregation rules for the Population field.")
Error Type |
Meaning |
NotFound |
The specified view or field was not found |
Error |
Invalid field specification |
Function |
Summary |
Gets the aggregation rules for a field |
|
Gets a list and description of the fields in a table |
|
Creates a joined view by linking fields in two existing views |
|
Creates a joined view by linking multiple fields in two existing views |
|
Modifies the file structure of a dBASE, fixed-format text, or fixed format binary table |
©2025 Caliper Corporation | www.caliper.com |