Showing results for 
Search instead for 
Did you mean: 

PowerApp - Patch Error - CDS Connector - Gov Cloud

Hi Experts


I am getting below error while using Patch for one of our custom entity “Participant Health History”. Inside Patch I am just setting Lookup value for Participant attribute which is contact entity. Attached is error snapshot.


Patch('Participant Health Histories', Defaults('Participant Health Histories'), {Participant: LookUp(Participants, Contact=currentParticipant.contactid)})


Error - "The Role column in the data source  you are updating expects a 'OptionSetValue' type and you are using a 'OptionSetValue' type"


This error comes only when app is opened in edit mode for first time. If cut/paste this formula and reload app, it works fine.

Any pointers will be appreciated.

Community Support
Community Support

Hi @Sachinbansal ,


To better understand your issue:

1. Do you meam the lookup Field column name is "Participant", and it looks up form Contact entity, right?

2. What is currentParticipant?


Maybe you made a mistake about the lookup entity, please try with the following formuals.

Patch('Participant Health Histories', Defaults('Participant Health Histories'), {Participant: LookUp(Contacts, Contact=currentParticipant.contactid)})

Best regards,



Hi @v-siky-msft 

Yes, to answer your first question.

currentParticipant is variable which holds data for selected participant from first screen.


"Participant" is display name for "Contact" entity only. So when you add contact as data source it appears as "Participants" only and same is being used in my Lookup formula.

Any updates?

Helpful resources

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

Power Apps Community Call

Power Apps Community Call- January

Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.


Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Users online (7,938)