Hello,
I have been working on a flow to update a record in dataverse from finance and operations. Whenever there is a null or '' value that is the result of an expression inside of a lookup column, I get the following error.
{ "error": { "code": "0x80060888", "message": "The supplied reference link -- -- is invalid. Expecting a reference link of the form /entityset(key)." } }
I am using the format found in this post, but I am still receiving the same error.
I have manually tried entering an expression for null, and still get the error. The only way that I've been able to successfully run the flow is to leave the box completely empty (no expressions). I could use a condition to test if it's empty and make multiple "update a row actions", but the more lookup columns I have, the more conditions and update actions I would need.
Here is the expression I'm using inside my lookup field:
(Note: I've tried '' and null and both fail)
if(empty(outputs('List_rows_from_selected_environment_(preview)_-_Customer_Group_GUID')?['body/value']),
'',
concat('/itemcustomergroups(', body('List_rows_from_selected_environment_(preview)_-_Customer_Group_GUID')?['value'][0]?['itemcustomergroupid'], ')')
)
I appreciate any help with this issue. If more information is needed from me, please let me know.
I figured out the issue. I was using the new copilot editor, and for some reason it would fail every time. I switched back to using the classic editor and changed the expression to use null if empty instead of ''. This seemed to fix the issue.