Scenario-
I have work orders with asset lookup. Asset has its own Checklist(Similar to service tasks). ' Asset check list is one entity and work order checklist is another entity.
when work order is created i need to fetch check list records for asset and create ' Work order checklists' from asset checklists.
I am not technical person, is there anyway to achieve this?
if no other option then kindly suggest how to write code .
Hi Leah
work order is getting created from agreement and asset field getting mapped on create itself. i tried with filter array as well. without filter work order checklist records are created. so issue is only at filter. i removed and added filter again and rechecked if i am choosing correct values.
is it something with filter with lookup field ?
Hi Sayali,
What I mean is that the Primary incident customer asset must be filled when work order created.If you don't fill it or fill it after creating order, the flow will appear following error.
From the screenshot, you can check that Primary incident customer asset field value is null.
And make sure that you have selected correct value in the flow.
Regards,
Leah Ju
Hi Leah,
Primary incident customer asset is not null, work order has value in Primary incident customer asset lookup .
can we try with filter array?
Hi Sayali,
It's a matter of test data, you can check ‘Primary Incident Customer Asset’ field of the work order, you must make it is not null.
Regards,
Leah Ju
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.
Hi Leah, Thanks for the reply, I tried as you suggested, and used _cfm_asset_value as given in output query.
but now i am facing another issue:
Error: A binary operator with incompatible types was detected. Found operand types 'Edm.Guid' and 'Edm.String' for operator kind 'Equal'.
Hi Sayali,
The best way I found how to make the Filters work on Dynamics is to:
1.Run the Flow with List Dynamics action without the filter.
2.Check the results of the Flow run, and look for the value you wish to be filtering on.
3.Copy the field name without id and use that as the filter.
Note that Lookup Fields may be the reason your filters are not working.
For example in my screen captures the field name of the filter I am trying to use is {new_assetid} but because it is a lookup when I did the List all records I found that the field I need to filter on is {_new_assetid_value}.
Regards,
Leah Ju
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.
This is the error:
HI Leah,
thank you for your reply. I followed all steps, but its failing at below step. Schema name of asset lookup in Asset Checklist entity is cfm_asset.
Hi Partner,
Has the problem been solved? Any updates?
Please click Yes under "Did this answer your question?" to close this thread.
Thanks.
Regards,
Leah Ju
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.
Hi Sayali,
From your description, I get following information:
Asset and Work order is 1:N relationship
Asset and Asset checklist is 1:N relationship
Work order and Work order checklist is 1:N relationship
Asset checklist and Work order checklist entities are custom entities you created?
You want to create Work order checklist with value from Asset checklist, right?
If so, maybe you can firstly use power automate to create an automated flow to achieve it, which is no-code and easier that code.
Go Power Automate(https://us.flow.microsoft.com/en-us/ )
2.Trigger
3.List rows action--Fetch Asset checklist for the asset that related to the new work order.
Note:new_assetid is logic name of the lookup field.
4.Add a new row action--create work order checklist with value from asset checklist.
5.Test.
One asset named 'asset1' has three asset checklist value.
when i create new workorder and select asset1, save and refresh current form, work order checklist records can created automatically.
Regards,
Leah Ju
Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 290,900 Super User 2024 Season 2
Martin Dráb 229,275 Most Valuable Professional
nmaenpaa 101,156