web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Patch a SharePoint Cho...
Power Apps
Unanswered

Patch a SharePoint Choice column to a Dataverse Choice column

(0) ShareShare
ReportReport
Posted on by 50

I have an existing SharePoint list 'MyList' that I am going to be patching updated records back to a dataverse table 'MyTable'. I have all of the fields working as expected except for the Assessment Status which is a choice column in both the SharePoint list and dataverse table. I have tried the below variations to get the choice columns to work, but noting is fixing the issues.

 

All of the error messages state that the:

 'assessment status' does not match the expected type 'OptionSetValue'(Assessment Status(MyTables)).Found Type 'Text'

 'assessment status' does not match the expected type 'OptionSetValue'(Assessment Status(MyTables)).Found Type 'Record'

 

Any assistance is greatly appreciated!

 

 

 

Patch(
 MyTable,
 Defaults(MyTable),
 
 {AsmtLookupMain: DataCardValue117.Text},
 {'Assessment Status': LookUp( 'MyList',Choices([@'MyList'].'Assessment Status') = DataCardValue115.Selected.Value).'Assessment Status'}
 
)

 

 

 

 

Patch(MyTable, 
 Defaults(MyTable), 
 {AsmtLookupMain:DataCardValue117.Text, 
 'Assessment Status': LookUp('MyList', 'Assessment Status'= DataCardValue115.Selected)
 }
)


Patch(MyTable, 
 Defaults(MyTable), 
 {AsmtLookupMain:DataCardValue117.Text, 
 'Assessment Status': LookUp('MyList', 'Assessment Status'= DataCardValue115.Selected.Value)
 }
)

 

 

 

 

Categories:
I have the same question (0)
  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @todaytoo The LookUp has to be performed on the Choices in Dataverse,

    'Assessment Status': LookUp(Choices('Assessment Status(MyTables)'), Value=DataCardValue115.Selected.Value)

     

    Please remember to give a 👍 and accept my solution as it will help others in the future.

     

  • todaytoo Profile Picture
    50 on at

    Thanks.

    I still get an error with this approach as well.

     

    'The type of this argument 'assuessmentstatus' does not match expected type 'OptionSetValue(Assessment Status(MyTable))'. Found type 'Record'

  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @todaytoo Could you share the full formula in the chat along with a screen shot.

  • todaytoo Profile Picture
    50 on at

    Sure, thank you for the help.

     

    I have a SP List (MyList) and a Dataverse Table (ASSIST_TABLE). I am attempting to patch new records from the SP list to the Dataverse table when a specific button is pressed. Using the below patch statement, all fields except the ‘Assessment Status’ copy to the Dataverse ‘ASSIST_TABLE’ correctly. The Assessment Status value from SP that needs to be updated in Dataverse is in DataCardValue115, this is a dropdown with 5 choice values to select from.

     

    The items value of the dropdown from SharePoint for Assessment Status is Choices([@MyList].'Assessment Status')

     

     

     

    Patch(
     ASSIST_TABLES,
     Defaults(ASSIST_TABLES),
     {
     AsmtLookupMain: DataCardValue117.Text,
     'Assessment Status': LookUp(Choices('Assessment Status (ASSIST_TABLES)'), Value = DataCardValue115.Selected.Value)
     }
     )

     

     

     

    unnamed-1.png
  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @todaytoo I tried something similar and it works,

    {'Person Category':Filter(Choices('Person Category Choices'), Text(Value)="Member")}
    Try changing the LookUp to Filter and also cast the Value to Text.
     

    Please remember to give a 👍 and accept my solution as it will help others in the future.

     
  • todaytoo Profile Picture
    50 on at

    Thanks. I get an error that it does not match the expected OptionSetValue, found type 'Table'.

  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @todaytoo Is the Data type for the 'Assessment Status' column in the ASSIST_TABLES Dataverse table of type Choices?

     

    Please remember to give a 👍 and accept my solution as it will help others in the future.

  • todaytoo Profile Picture
    50 on at

    Yes, in both SharePoint and Dataverse the 'Assessment Status' column is data type choice.

     

    My form is populating data from SharePoint. In the assessment status card (DataCardValue115) the Items value is Choices([@'MyList'].'Assessment Status'). The dataverse 'Assessment Status' column has a value of Choices('Assessment Status (ASSIST_TABLE)'), this is where I am trying to patch the data to.

    Screenshot 2023-03-31 162446.png
  • Krishna09 Profile Picture
    234 on at

    Hello @CNT @todaytoo ,

    I am facing same kind of issue, thought with your experience you can guide me solve this. using prow automate I saved excel data to sharepoint. I open sahrepoint data in gallery(Power apps) and then patch the data to dataverse.

    Here I am saving sharepoint data to a dataverse table.  I find below errors in both screnarios(filter and lookup)

    Krishna09_1-1684223323932.pngKrishna09_2-1684223352845.png

     

    Krishna09_3-1684223432199.png

     

  • cathrose Profile Picture
    22 on at

    I am having a similar issue. 

     

    I have a sharepoint list FLAquestions with a choices column Reporting_Qtr and a dataverse table FLAanswers with a choices column Reporting_Frequency. Both Reporting_Frequency and Reporting_Qtr have choices Q1, Q2, Q3, Q4. 

     

    I am trying to patch Reporting_Qtr of gallery items to the dataverse table but I am getting the following error -

    This type of argument reporting_frequency does not match the expected type 'OptionSetValue (Qtr)'. Found type 'table'

     

    Can anyone assist with this? 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 356 Most Valuable Professional

#2
11manish Profile Picture

11manish 225 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 211

Last 30 days Overall leaderboard