Hi
I have a DataVerse table called JukeBoxJuryMembers which has a Choices field called Colours with values "WHITE", "BLACK" and "RED".
I want to add a record to this table. I use "RED" for the Colours field but I get an error "The runtime value "RED" to be converted doesn't have the expected format 'Integer/int32'.
So I try and get the equivalent integer value for the Colour "RED" by querying the table String maps with the filter attributename eq 'Colours' and value eq 'RED' and objecttypecode eq 'jukeboxjurymembers'.
I get an error The entity with a name = 'jukeboxjurymembers' with namemapping = 'Logical' was not found in the MetadataCache.
What am I doing wrong ?
Thanks
Nigel
Can you tell us if you’re doing a canvas app, model driven app or something else to add a record?
Please paste a screenshot of the error thrown too, so we can see context of where this is coming from.
based on the Odata query it seems you may be using JavaScript or a Power Automate Flow…
if you’re using a flow, choices should be a dropdown in the UI. Don’t enter the words “red”, simply use the dropdown to select the Red option. If you enter a formula, then you have to use the option set number value. For testing purposes just enter the number value for Red directly without commas. It should work then.
Sorry, My bad I should have said this was happening with a PowerAutomate Flow.
Regards
Nigel
Hi @NigelP ,
Do you want to patch a new record in Dataverse table with choice column is "RED"?
You can either show me the code which is reporting an error, or you can try this code first.
Patch(DataverseTableName,Defaults(DataverseTableName),{Column1:"test",ChoiceColumnName:ChoiceTableName.RED})
Best regards,
Rimmon
mmbr1606
22
Super User 2025 Season 1
stampcoin
17
ankit_singhal
11
Super User 2025 Season 1