cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Caroline
Level: Powered On

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)

2 REPLIES 2
Community Support Team
Community Support Team

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.

 

Regards,

Mona

 

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.
Caroline
Level: Powered On

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)

 

Cheers

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 111 members 5,971 guests
Please welcome our newest community members: