

The records of the table aren't extracted and instead the entire table is added as a cell of the record. Same as the previous example except that the table is wrapped in a record. Generated collection, a musical scale formed by repeatedly adding a constant interval around the chromatic circle. Collection class, in object-oriented programming. Collections care, to prevent or delay the deterioration of cultural heritage. The data source begins with these contents:ĬlearCollect( IceCream, ) Collection 1, a database of sets of email addresses and passwords. In these examples, you'll erase and add to a collection that's named IceCream. The collection that you want to clear and then add data to.Įxamples Clearing and adding records to a data source One or more records or tables to add to the data source. If it doesn't already exist, a new collection is created. The data source that you want to add data to. For more information, see the delegation overview. A warning may appear at authoring time to remind you of this limitation and to suggest switching to delegable alternatives where possible. The result may not represent the complete story. Only the first portion of the data source will be retrieved and then the function applied.

When used with a data source, these functions can't be delegated. ClearCollect can only be used in a behavior formula. With a single function, ClearCollect offers the combination of Clear and then Collect.ĬlearCollect returns the modified collection as a table. And then adds a different set of records to the same collection. The ClearCollect function deletes all the records from a collection. It can only be used in a behavior formula. You can use the Remove function to selectively remove records.Ĭlear has no return value. Use caution as this will remove all records from the data source's storage and can affect other users. You can use RemoveIf( DataSource, true ) for this purpose. Note that Clear only operates on collections and not other data sources. The columns of the collection will remain. The Clear function deletes all the records of a collection. Collect can only be used in a behavior formula.
#COLLECTION PATCH#
You can also use the Patch function to create records in a data source.Ĭollect returns the modified data source as a table. Before using a collection in this manner, review working with variables. Collections don't enjoy this benefit and their use can make your app harder to create and understand. Canvas apps are based on formulas that automatically recalculate as the user interacts with an app. If the data source doesn't already exist, a collection is created.Ĭollections are sometimes used to hold global variables or make a temporary copy of a data source. The columns for other data sources are fixed by the data source and new columns can't be added. When used with a collection, additional columns will be created as needed. To do this, wrap the table in a record first. The table isn't added as a nested table to a record.
