Showing results for 
Search instead for 
Did you mean: 
Resolver I
Resolver I

collect won't update data source (CDS)

Hi there


I  have the following collect formula:


Collect(test_Course_Link,{Test_A2:LearnerID.Selected,IntakeNumber:IntakeNumberEnrol.Selected.Value, test_Courses:CourseIDEnrol.Selected, SWN:SWNInput.Text})


There is no error warning on the formula, and when I test it, it seems be doing something, but the test_Course_Link entity isn't being updated.


I tested it by changing test_Course_Link for a collection (test_collect), and it worked fine, so I tried to then push the collection back to the entity by using:


ClearCollect(test_collect,Test_A2:LearnerID.Selected,IntakeNumber:IntakeNumberEnrol.Selected.Value,test_Courses:CourseIDEnrol.Selected, SWN:SWNInput.Text});Collect(test_Course_Link,test_collect)


Same problem - still not updating the data source.

Any ideas on what is happening here?


(Yesterday, it would update the data souce, but with the two lookup fields (Test_A2 and test_Courses) ommited. I can't be sure though that the formula is exactly the same, as I have spent quite a bit of time playing around trying to fix it)

Community Support
Community Support

Re: collect won't update data source (CDS)

Hi @Caroline,


Among Collect, Clear, and ClearCollect functions, you can only use Collect function to add records to a data source. You can also use the Patch function to create records in a data source.


Are LearnerID/IntakeNumberEnrol/CourseIDEnrol all dropdown controls? What are the DATA TYPES of Test_A2/IntakeNumber/test_Courses fields in this entity? Notice that when you add a record to entity, all the Required fields must be included.





Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Resolver I
Resolver I

Re: collect won't update data source (CDS)

@v-monli-msft Thanks Mona. As you will see from the two formulas I tried, it was the Collect command that I was using to write a new record to the data source. (Please disregard the emojis - It has replaced my colons followed by 'S'.)


LearnerID/IntakeNumberEnrol/CourseIDEnrol are all dropdown controls.


Test_A2 and test_Courses fields are Look ups in the entity, and IntakeNumber is a text field (because the number is hyphenated, it can't be a number field)



Helpful resources


New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

August 2020 CYST Challenge

Check out the winners of the recent 'Can You Solve These?' community challenge!

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications


Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Users online (4,430)