Hi everyone,
I'm having a very specific issue when trying to populate a Dataverse lookup field dynamically from Power Automate.
CONTEXT
I have a flow triggered from a Dataverse table called Cotizaciones using:
- When a row is added, modified or deleted
Inside the flow, I use Add a new row to create records in another Dataverse table.
That target table contains a lookup column:
- Cotización => lookup to the Cotizaciones table:
WHAT I NEED TO DO
I need to assign the current quotation record (the one that triggered the flow) to that lookup field dynamically.
From the trigger, I already have the record ID:
@{triggerOutputs()?['body/new_cotizacionesid']}
This value is the correct GUID of the current row in Cotizaciones.
PROBLEM
When I use that value to populate the lookup field in Add a new row, the flow fails with this error:
{
"error": {
"code": "0x80060888",
"message": "URL was not parsed due to an ODataUnrecognizedPathException. Resource not found for the segment 'GUID' provided in the URL."
}
}
So the issue seems to be specifically related to how the lookup field expects the related record ID to be passed.
MY QUESTION
What is the correct way to populate a Dataverse lookup field dynamically in Power Automate?
More specifically:
- Is the GUID from the trigger enough?
- Should it be passed in another format?
- Should I use dynamic content, an expression, or an OData reference?
- What is the correct way to make a lookup field accept the current row ID from the trigger?
IMPORTANT NOTE
The relationship itself is correctly configured in Dataverse.
The issue is not the data model itself, but specifically how to populate the lookup field dynamically in the flow.
Any help would be greatly appreciated. Thanks in advance