Skip to content

Commit

Permalink
Validation Info: link-entity use primid, not for M-M
Browse files Browse the repository at this point in the history
  • Loading branch information
rappen committed Jan 15, 2022
1 parent 2a6484d commit e5c798b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion FetchXmlBuilder/AppCode/Validations.cs
Expand Up @@ -36,7 +36,8 @@ internal static ControlValidationResult GetWarning(TreeNode node, FetchXmlBuilde
return new ControlValidationResult(ControlValidationLevel.Warning, "Link-Entity must include Name, To, From.");
}

if (fxb.GetAttribute(name, node.Value("from")) is AttributeMetadata fromAttr && fromAttr.IsPrimaryId == false)
if (node.Value("intersect") != "true" &&
fxb.GetAttribute(name, node.Value("from")) is AttributeMetadata fromAttr && fromAttr.IsPrimaryId == false)
{
return new ControlValidationResult(ControlValidationLevel.Info, "Links to records that aren't parents may cause paging issues.", "https://markcarrington.dev/2021/02/23/msdyn365-internals-paging-gotchas/#multiple_linked_entities");
}
Expand Down

0 comments on commit e5c798b

Please sign in to comment.