Hi everyone,
Background
I have two custom Dataverse tables (People_Data and Role_Data). These two tables are related using a common identifier called “RoleAssignment_ID”.

The relationship cardinality is one to-many.

I have a Gallery control and its items property is associated to People_Data. The OnSelect property uses the classic practice of declaring the selected item as a variable instead of Gallery.Selected. E.g.
Set(
VarRecordEmployee,
ThisItem
);
Problem
I have a label control in a form. The DataSource for the form is VarRecordEmployee. There is a field in that form called “Role Name” assigned to the label control. This field is a free text type and comes from the Role_Data table.
Because the DataSource for VarRecordEmployee is from the People_Table, and I want to return the Role Name from the Role_Table based on the RoleAssignment_ID value in the People_Table, the traditional method is to lookup the RoleAssignment_ID field in the People_Table and then return the associated Role Name from the Role Table.
However, because the tables are related, I want to leverage that relationship and display the associated Role Name based on the RoleAssignment_ID in VarRecordEmployee without using a lookup function. However, this results in blank.

I can always use a lookup function to get this work. For example the below syntax returns the value I need based on the RoleID.
If(
Form_General.Mode = FormMode.New,Blank(),
LookUp(Role_Data, RoleID = VarRecordEmployee.new_RoleAssignment_ID.RoleID).Role_Name)
But I did not think I would need to do this given the tables are related. I would have thought I would see the associated Role Name based on the RoleAssignment_ID. I suspect the answer could be obvious?
best regards,
Ami