{"title":"DataItemLink property on report data items","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/properties/devenv-dataitemlink-reports-property/","by":"JOP-AL","license":"Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/properties/devenv-dataitemlink-reports-property, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact.","credit":"Microsoft Corporation, CC BY 4.0","origin":"https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/properties/devenv-dataitemlink-reports-property","source":{"name":"Business Central developer and IT pro docs","repo":"https://github.com/MicrosoftDocs/dynamics365smb-devitpro-pb","commit":"828b6ee72fcd75755627cd6011f3d20899217ab2","date":"2026-11-19"},"checked":"2026-11-19","description":"Learn how the DataItemLink property filters a child report data item by matching its fields with fields in an ancestor data item.","date":"2026-10-01","meta":{"topic":"reference"},"outline":[{"level":1,"title":"DataItemLink property on report data items","slug":"dataitemlink-property-on-report-data-items","at":0,"chars":1603},{"level":2,"title":"Applies to","slug":"applies-to","at":305,"chars":33},{"level":2,"title":"Remarks","slug":"remarks","at":338,"chars":1059},{"level":2,"title":"Related information","slug":"related-information","at":1397,"chars":206}],"text":"# DataItemLink property on report data items\n> Version: _Available from runtime version 1.0._\nSpecifies matching fields in two data items that are linked by the devenv-dataitemlinkreference-property. Set DataItemLink on the child data item. The referenced data item can be its parent or another ancestor.\n## Applies to\n Report data items\n## Remarks\nUse the following syntax:\n`<Field>=field(<ReferenceField>)`\nPlaceholder|Description\n`<Field>`|A field from the child data item.\n`<ReferenceField>`|A field from the parent or ancestor data item identified by the devenv-dataitemlinkreference-property.\nTo link more than one pair of fields, separate the links with commas.\nThe DataItemLink property sets a filter on the child data item. The filter selects records that have the same field values in the referenced and child data items.\nFor example, a Customer parent data item and a `Sales Header` child data item both contain a customer number. Set DataItemLinkReference on the child data item to the Customer data item. Then set DataItemLink on the child data item as follows:\n```al\nDataItemLink = \"Sell-to Customer No.\" = field(\"No.\");\n```\nThis filter selects sales headers for the current customer. You can create the same filter in the ../triggers-auto/reportdataitem/devenv-onpredataitem-reportdataitem-trigger of the child data item:\n```al\nSetRange(\"Sell-to Customer No.\", Customer.\"No.\");\n```\n## Related information\n../triggers-auto/reportdataitem/devenv-onpredataitem-reportdataitem-trigger\ndevenv-dataitemlinkreference-property\nDataItemLink property for queries<devenv-dataitemlink-query-property>"}