cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

Sharepoint List (single choice drop-down) Choice Field shows the ID not the value

we're using flow to create new list items in sharepoint online, where we poplulate a (single-value) choice field with text that perfectly matches the choices available. This has worked in the past, but lately, newly created records show the choice IDs, not the values.

 

we tried to trouble shoot this by building a very simple flow that creates a new record and simply sets the choice field. but even here the ID of the choice shows up, not the value.

 

we get the below in the output of the "Create Item" step

...

,

"someColumnName": {
"@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
"Id": 0,
"Value": "aFineChoice"
},
"someColumnName#Id": 0,
...
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Regular Visitor

Re: Sharepoint List (single choice drop-down) Choice Field shows the ID not the value

Alice, Scott, thanks for your help on this. Turns out neither flow nor sharepoint online are to blame here.

 

We found the root cause of our issue: we run an azure function triggered at (flow based) list item creation. the function looks up a bunch of stuff and updates the new record. in the code base of that function the choice field in question here is modeled as an enum.

 

having recently migrated from csom to the ms graph sharepoint api's we haven't explicitly applied ToString() to the enum values - that's how the ID's managed to sneak back in. Problem solved. yay.

 

Cheers, Gregor

View solution in original post

4 REPLIES 4
Highlighted
Super User III
Super User III

Re: Sharepoint List (single choice drop-down) Choice Field shows the ID not the value

@gv73 

I just ran a quick test creating a new list item and setting the value in a choice column and had no issues.  I selelcted "enter custom value" and referenced a variable.

Can you confirm that this is a choice column an not a lookup column?

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott
Highlighted
Regular Visitor

Re: Sharepoint List (single choice drop-down) Choice Field shows the ID not the value

thanks Scott. yes, i'm positive it's a choice column. 4 hard coded choices - all text...

cheers, Gregor

Highlighted
Community Support
Community Support

Re: Sharepoint List (single choice drop-down) Choice Field shows the ID not the value

Hi @gv73 ,

 

Could ypou please share a screenshot of the created records which show the choice IDs, not the values?

 

Best regards,

Alice       

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

Highlighted
Regular Visitor

Re: Sharepoint List (single choice drop-down) Choice Field shows the ID not the value

Alice, Scott, thanks for your help on this. Turns out neither flow nor sharepoint online are to blame here.

 

We found the root cause of our issue: we run an azure function triggered at (flow based) list item creation. the function looks up a bunch of stuff and updates the new record. in the code base of that function the choice field in question here is modeled as an enum.

 

having recently migrated from csom to the ms graph sharepoint api's we haven't explicitly applied ToString() to the enum values - that's how the ID's managed to sneak back in. Problem solved. yay.

 

Cheers, Gregor

View solution in original post

Helpful resources

Announcements
Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Community Conference

Power Platform Community Conference

Find your favorite faces from the community presenting at the Power Platform Community Conference!

Top Solution Authors
Top Kudoed Authors
Users online (5,022)