Embedded Canvas Apps

Challenge #2: Many-to-one relationships

Challenge #2

Displaying a many-to-one relationship using the ModelDrivenFormIntegration controls results in no data being displayed. For example, trying to display the Primary Contact of an Account using the formula shown below will result in no data being displayed.

[@ModelDrivenFormIntegration].Item.'Primary Contact'

Many-to-one relationship using ModelDrivenFormIntegration (click to enlarge)

Trick #2

Using LookUp to fetch the complete Account record using the ModelDrivenFormIntegration control and in turn, using that record to fetch the Primary Contact does display the correct data. The following formula works to display the Primary Contact of an Account.

LookUp(Accounts, Account = [@ModelDrivenFormIntegration].Item.Account).'Primary Contact'

LookUp to display many-to-one relationship (click to enlarge)

Have fun! Get addicted!

1 thought on “Challenge #2: Many-to-one relationships”

Leave a Reply