web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Multiple Data Sources ...
Power Apps
Unanswered

Multiple Data Sources and Entity Relationships

(0) ShareShare
ReportReport
Posted on by 10

Hi there, I am new to powerApps so please excuse my lack of knowedge!

 

I have a simple relationship set up on a Project Name Entity that links back to Contacts so i can link Clients and Site Managers to a specific project.

 

The Lookup field shows in the Entity and I can select the correct name in Excel to load the databse.

 

When I create a PowerApp for the Project Entity I am unable to see the Lookup Field but can load it by using Contact.ContactId. The problem is that this, correctly, shows me the ContactId.


What I need to do is to display the FullName not the ContactId. I have one Data Connection set up for the Project Entity.

 

Please advise!


Regards

Categories:
I have the same question (0)
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    When you say "I have a simple relationship set up on a Project Name Entity that links back to Contacts so i can link Clients and Site Managers to a specific project." what do you mean?  Do you mean you have two tables in the spreadsheet that have columns that relate to each other, or two spreadsheets that relate to each other?  Is Contacts a column or a table?

     

    I'm battling to decrypt your explanation a bit....but I'll make some assumptions;

    To start, if you connect PowerApps to an excel spreadsheet as a data source, it will look for a specific Table to connect to. 

    It does not automatically connect to the entire spreadsheet, and it will ONLY connect to one Table per data source that you have defined - i.e. those parts of your spreadsheet you've created a table with by pushing ctrl+T, or by selecting an area and clicking Insert, Table.

     

    If you have two tables with relational data in the spreadsheet, you will need to connect to both of them, and then do lookups across them to retrieve relational data.  Same applies if you have two spreadsheets with different tables in them that you want to connect to.  It sounds like you're loading two although it's impossible to tell from your explanation whether you're using a data source with collections or multiple data sources.

     

    Contact.ContactId sounds like a Contact datasource with a column labeled ContactId.  Except you say you have one data connection set up for the project entity which sounds like a different source.  Can you try and clarify this, perhaps with some screenshots?  Try to clarify how the spreadsheet is set up with it's tables, where the data you're trying to find is located in the spreadsheet and how you are accessing it with PowerApps.

  • finnt Profile Picture
    10 on at
    Sorry. I am using the Common Data Model not a spreadsheet.

    Contacts and Project entities are set up separately with a relationship created from projects to contacts so I can link people to the project record.

    Within powerapps I have on data connection that gets created when I create the app from within Powerapps.

    Would u prefer some screen shots?
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I haven't actually played with the CDM yet, this will give me an excuse to 🙂

     

    Quick shot in the dark though - I notice that the default data in Contact entity has a fair bit of data but none of the entries has anything under FullNames, so you'd have to put some in there to pull them out....

    Assuming you've got data in there, will Contact.FullName not bring back what you're after? 

     

    If you want to look at the data, I find a handy way to do it is to create a collection of the data and then go look at it under Collections.

    Use a button or OnVisible screen event to action the following;

    ClearCollect(MyCollectionOfContact, Contact)

     

     

    Push the button, or navigate away from and back to the screen to trigger the Onvisible event.

    Click Content menu, then select Collections

    Select your MyCollectionOfContact collection - you should see columns with data pop up like an excel view.

     

    Hope this helps

     

  • finnt Profile Picture
    10 on at

    Sorry, perhaps I have not been as clear as I should off.

     

    1. Contact is a default Entity in Common Data Service.;

    2. I have created a custom entity called Project Name with a Lookup Relationship created back to Contact. (only choice available when created a relationship)

     

    3. The problem I have is that I cant bind the Contact Relationship to the FullName column in Contact. It binds to the ContactID and that is what I see in PowerApps when I try to read it. What I want to show is the text that is in the FullName colum in the Contact Entity.

     

    When I create the app the ContactID comes up but I cant seem to translate that to the FullName text. I assume I need to perform a LookUp?

     

    1.png2.png
    Any help would be appreciated.


    Regards

     

    The Data I am looking to show is being retrieved from CDS as when I edit the entry in PowerApps I can see the FullName. It is this I want to show in the PowerApp not the ContactID.3.png

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hmmm...the relationship seems to provide both ContactId and FullName for me.

    There's a slight chance you're just missing the control field selector...

     

    I created "Demo Project Data" entity.

    Created Lookup relationship it to the Contact entity 

    Created a new app off the "Demo Project Data" entity

     

    On the EditScreen screen, with the EditForm card selected, there is by default a Contact Dropdown.  

    If you select the Contact card or its dropdown, the properties screen on the right shows the cards, you can click the "..." menu to access configurable options as well as advanced options for a specific card.  For the Contact card/dropdown;

     

    The default Display Fields entry is 1.

    Below this you have two fields you can edit.  By default there is only 1 field displayed, so the value of the first field will be what you see in the dropdown - which is ContactId by default. 

    If you click the dropdown arrow next to this, you can select FullName (so both fields 1 and 2 will be FullName....you're only displaying Field 1, so it doesn't matter if they're both the same)

    I just changed the first lookup field to be FullName.

     

    Word of caution though -  as I mentioned before, by default the "FullName" column for the Contact entity is EMPTY, so unless you've put data in there, you won't see anything....

    Red circle marks the dropdown to select FullName as the display fieldRed circle marks the dropdown to select FullName as the display field

     

     

     

     

  • finnt Profile Picture
    10 on at

    Makes perfect sence. I have tested and the box changes to EMPTY. I am positive that I have data in the Entity?

     

    Also how would I populate the FullName onto the BrowseScreen?

     

    Very grateful for your help.

    4.png

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi finnt,

      

    Just to clarify;

    • While the Contact entity has some dummy data in it, the FullName column is blank because none of the contacts have all their names - they only have first name and surname, not middle names.
    • The FullName column on the Contact entity is a derived field - meaning you can't capture data into it directly.  It derives values from the Name_GivenName, Name_Surname and Name_MiddleName fields.  Only if a contact has values for all three name fields, will FullName get a value (which will be the three names concatenated).
    • In order to put data into the FullName field, you need to give one of the existing dummy contacts a middle name, or create a new one with all three.

     

    If you create an app with the Contact entity as the source, you can run the app and edit some of the existing contacts.  By adding a middle name, you can then get their FullName column to populate.

     

    1: New app from Contact entity1: New app from Contact entity2: View details of contact2: View details of contact

    3: Edit Contact to create Middle Name3: Edit Contact to create Middle Name4: Saving the contact will populate Full Name with all three names4: Saving the contact will populate Full Name with all three names

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

    Lastly, loading up the Project entity as a new app, you can run the lookup control on the add new screen - just clicking the downarrow will retrieve all values (or at least as many as the control allows) - typing in a word will filter the result set accordingly.

    5: Create app from project entity, Contact control will show FullNames5: Create app from project entity, Contact control will show FullNames

     

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 505

#2
WarrenBelz Profile Picture

WarrenBelz 502 Most Valuable Professional

#3
Haque Profile Picture

Haque 324

Last 30 days Overall leaderboard