I’ve successfully set up Relationships between two tables within Dataverse, and I know these work correctly (via Forms in a Model Driven App, and via Galleries in a Canvas App (both Apps set to refer to the same Dataverse tables at source)). Given the relationships are at the data layer, I had anticipated that a Flow (in Power Automate) would understand that one table is related to another. I can’t identify this functionality and additionally, it seems both nonsensical and in fact impossible within Flow to introduce a step to look up a record on a corresponding table – since the GUID for the corresponding record in a second table is not known and can’t be determined.
I’ve attached a screenshot of a very basic Flow, which is triggered during a Business Process Flow run from within a Model Driven App (formal trigger name is: “When a flow step is run from a business process flow”). The Flow ‘knows about’ the master record to work on, given this record is already related to the BPF – in this example, the Table is EquipmentOrders. To test this, I put an attribute, ‘Quantity’, in to a Compose – and the correct value was presented on run of the Flow.
However, the intention of this Flow is that when submitted, the stock level of the equipment ordered by the user, stored in table EquipmentStockQuantities, will be reduced. Normally when using SharePoint as the data source, I would expect to apply an OData filter at this step and filter using dynamic data to grab one unique row. However, these two tables are related at the data layer in Dataverse so I can’t see why this is necessary in Flow. The BPF or the Flow will not know the GUID of the appropriate row in EquipmentStockQuantities and as that’s the primary key, that’s how I’d want to identify the correct row.
Not shown, but for completeness, the action ‘Update a row’ wants the Row ID – same problem in that I don’t have it.
Another [inefficient but again for illustrative purpose] could be that I use the List rows action for table EquipmentStockQuantities and retrieve all the records on the list, but again, I can’t see how I would then refine that list to identify the single record to update (using OData filtering etc) since the GUID doesn’t seem to be known to the Flow – even though the two tables are related.
I’m sure there must be a very straightforward solution to this, as this seems fundamental to being able to work routinely with two related tables and two related records in Dataverse, but I can’t spot it and all my research hasn’t revealed it. Can anyone advise how the appropriate (related) record in the second table, EquipmentStockQuantities, can be reliably located by the Flow and updated accordingly?
Thank you very much for any assistance!